Clean up property iterator constructor a bit.
authorKristian H?gsberg <krh@redhat.com>
Thu Jan 10 23:03:03 2008 -0500 (2008-01-10)
changeset 98ec850cbd6935
parent 97 41bf485e6154
child 99 7e5f2050db0e
Clean up property iterator constructor a bit.
razor.c
     1.1 --- a/razor.c	Thu Jan 10 22:50:51 2008 -0500
     1.2 +++ b/razor.c	Thu Jan 10 23:03:03 2008 -0500
     1.3 @@ -1007,16 +1007,13 @@
     1.4  
     1.5  	pi = zalloc(sizeof *pi);
     1.6  	pi->set = set;
     1.7 -	pi->property = set->properties.data;
     1.8  	pi->end = set->properties.data + set->properties.size;
     1.9 -	if (package) {
    1.10 +
    1.11 +	if (package)
    1.12  		pi->index = (unsigned long *)
    1.13  			set->property_pool.data + package->properties;
    1.14 -		pi->last = 0;
    1.15 -	} else {
    1.16 -		pi->index = NULL;
    1.17 -		pi->last = 0;
    1.18 -	}
    1.19 +	else
    1.20 +		pi->property = set->properties.data;
    1.21  
    1.22  	return pi;
    1.23  }