X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;f=wma_afh.c;h=8bff7cfcaa98f8ae3bdfb00f87545c70c7927d94;hb=be5daec66f163725489f42d512659a8af5c3fd59;hp=a6fbecca59252e9ee403d7c9e0f454a0eff16e13;hpb=26a032fffa6c6e6f092ed3d14c2b5f08e5c736d6;p=paraslash.git diff --git a/wma_afh.c b/wma_afh.c index a6fbecca..8bff7cfc 100644 --- a/wma_afh.c +++ b/wma_afh.c @@ -195,7 +195,7 @@ static int wma_make_chunk_table(char *buf, size_t buf_size, uint32_t packet_size size_t ct_size = 250; int ret, count = 0, num_frames, num_superframes; - afhi->chunk_table = alloc(ct_size * sizeof(uint32_t)); + afhi->chunk_table = arr_alloc(ct_size, sizeof(uint32_t)); afhi->chunk_table[0] = 0; afhi->chunk_table[1] = afhi->header_len; @@ -622,7 +622,7 @@ static int wma_rewrite_tags(const char *map, size_t mapsize, if (top.reserved2 != 2) return -E_NO_WMA; p++; /* objects start at p */ - top.objects = alloc(top.num_objects * sizeof(struct asf_object)); + top.objects = arr_alloc(top.num_objects, sizeof(struct asf_object)); ret = read_asf_objects(p, top.size - (p - map), top.num_objects, top.objects, &ton); if (ret < 0)