Fix bug when merging a package with no files
authorJ. Ali Harlow <ali@juiblex.co.uk>
Wed Jun 08 15:15:27 2016 +0100 (2016-06-08)
changeset 4707a38fc77fbde
parent 469 4aaa4b4b29e5
child 471 a3e5e3eaf224
Fix bug when merging a package with no files
librazor/merger.c
     1.1 --- a/librazor/merger.c	Fri Apr 15 16:58:07 2016 +0100
     1.2 +++ b/librazor/merger.c	Wed Jun 08 15:15:27 2016 +0100
     1.3 @@ -464,6 +464,10 @@
     1.4  
     1.5  	r = pool->size / sizeof *q;
     1.6  	p = list_first(files, source_pool);
     1.7 +
     1.8 +	if (!p)
     1.9 +		return;
    1.10 +
    1.11  	while (p) {
    1.12  		q = array_add(pool, sizeof *q);
    1.13  		q->data = map[p->data];