wmc: Get rid of xmalloc casts.

This commit is contained in:
Alexandre Julliard 2006-08-26 21:35:32 +02:00
parent 1659f53c3a
commit 1916cb1e19
3 changed files with 5 additions and 5 deletions

View File

@ -437,7 +437,7 @@ static void do_add_token(tok_e type, token_t *tok, const char *code)
static lanmsg_t *new_lanmsg(lan_cp_t *lcp, WCHAR *msg)
{
lanmsg_t *lmp = (lanmsg_t *)xmalloc(sizeof(lanmsg_t));
lanmsg_t *lmp = xmalloc(sizeof(lanmsg_t));
lmp->lan = lcp->language;
lmp->cp = lcp->codepage;
lmp->msg = msg;

View File

@ -128,7 +128,7 @@ char *dup_basename(const char *name, const char *ext)
namelen = strlen(name);
/* +4 for later extension and +1 for '\0' */
base = (char *)xmalloc(namelen +4 +1);
base = xmalloc(namelen +4 +1);
strcpy(base, name);
if(!strcasecmp(name + namelen-extlen, ext))
{
@ -172,7 +172,7 @@ char *xstrdup(const char *str)
char *s;
assert(str != NULL);
s = (char *)xmalloc(strlen(str)+1);
s = xmalloc(strlen(str)+1);
return strcpy(s, str);
}
@ -198,7 +198,7 @@ WCHAR *xunistrdup(const WCHAR * str)
WCHAR *s;
assert(str != NULL);
s = (WCHAR *)xmalloc((unistrlen(str)+1) * sizeof(WCHAR));
s = xmalloc((unistrlen(str)+1) * sizeof(WCHAR));
return unistrcpy(s, str);
}

View File

@ -152,7 +152,7 @@ int main(int argc,char *argv[])
cmdlen = 4; /* for "wmc " */
for(i = 1; i < argc; i++)
cmdlen += strlen(argv[i]) + 1;
cmdline = (char *)xmalloc(cmdlen);
cmdline = xmalloc(cmdlen);
strcpy(cmdline, "wmc ");
for(i = 1; i < argc; i++)
{