a bunch of fixes

git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@10 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
Lennart Poettering 2004-06-14 18:38:50 +00:00
parent edfad835cb
commit c8cf0c1ce9
8 changed files with 28 additions and 21 deletions

View file

@ -152,8 +152,8 @@ int idxset_put(struct idxset*s, void *p, uint32_t *index) {
s->hash_table[h] = e;
/* Insert into array */
extend_array(s, s->index);
a = array_index(s, s->index);
extend_array(s, e->index);
a = array_index(s, e->index);
assert(a && !*a);
*a = e;
@ -185,6 +185,9 @@ void* idxset_get_by_index(struct idxset*s, uint32_t index) {
if (!(a = array_index(s, index)))
return NULL;
if (!*a)
return NULL;
return (*a)->data;
}