summaryrefslogtreecommitdiff
path: root/archival/rpm.c
diff options
context:
space:
mode:
authorMike Frysinger2005-08-16 05:32:42 +0000
committerMike Frysinger2005-08-16 05:32:42 +0000
commit1eef0c4571d6319e67005944b7c20307fb8f5b15 (patch)
tree47b604f693a34a36895b4cfd4cfb47ccf6e3c029 /archival/rpm.c
parent71224980e1a26977c0884c679a51c685ad46a44f (diff)
downloadbusybox-1eef0c4571d6319e67005944b7c20307fb8f5b15.zip
busybox-1eef0c4571d6319e67005944b7c20307fb8f5b15.tar.gz
Bernhard Fischer says: use xmalloc() instead of malloc()
Diffstat (limited to 'archival/rpm.c')
-rw-r--r--archival/rpm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/archival/rpm.c b/archival/rpm.c
index 41c6129..fa8db53 100644
--- a/archival/rpm.c
+++ b/archival/rpm.c
@@ -243,7 +243,7 @@ rpm_index **rpm_gettags(int fd, int *num_tags)
storepos = lseek(fd,0,SEEK_CUR) + header.entries * 16;
while (header.entries--) {
- tmpindex = tags[tagindex++] = malloc(sizeof(rpm_index));
+ tmpindex = tags[tagindex++] = xmalloc(sizeof(rpm_index));
read(fd, tmpindex, sizeof(rpm_index));
tmpindex->tag = ntohl(tmpindex->tag); tmpindex->type = ntohl(tmpindex->type); tmpindex->count = ntohl(tmpindex->count);
tmpindex->offset = storepos + ntohl(tmpindex->offset);