diff options
author | Dan McGee <dan@archlinux.org> | 2011-09-30 18:46:44 +0200 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2011-10-12 21:01:25 +0200 |
commit | 89fe19f3e102dae379c00e5b45dd1d42a6963962 (patch) | |
tree | 8f85b781239cdbba896ab6aaed240d41973a5027 /lib/libalpm/sync.c | |
parent | 980b3faea5ecfb54186bf74b2b6d79e0cb7836ea (diff) | |
download | pacman-89fe19f3e102dae379c00e5b45dd1d42a6963962.tar.gz pacman-89fe19f3e102dae379c00e5b45dd1d42a6963962.tar.xz |
Convert MALLOC to actually call malloc()
If you need zero-filled allocations, call CALLOC() instead.
This was from the original definition of these macros in commit
cc754bc6e3be0f3; hopefully our code is in the shape it needs to be to
switch this behavior.
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/sync.c')
-rw-r--r-- | lib/libalpm/sync.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libalpm/sync.c b/lib/libalpm/sync.c index 08d634d6..968625b1 100644 --- a/lib/libalpm/sync.c +++ b/lib/libalpm/sync.c @@ -682,11 +682,11 @@ static int apply_deltas(alpm_handle_t *handle) } else { /* len = cachedir len + from len + '/' + null */ len = strlen(cachedir) + strlen(d->from) + 2; - CALLOC(from, len, sizeof(char), RET_ERR(handle, ALPM_ERR_MEMORY, 1)); + MALLOC(from, len, RET_ERR(handle, ALPM_ERR_MEMORY, 1)); snprintf(from, len, "%s/%s", cachedir, d->from); } len = strlen(cachedir) + strlen(d->to) + 2; - CALLOC(to, len, sizeof(char), RET_ERR(handle, ALPM_ERR_MEMORY, 1)); + MALLOC(to, len, RET_ERR(handle, ALPM_ERR_MEMORY, 1)); snprintf(to, len, "%s/%s", cachedir, d->to); /* build the patch command */ |