mirror of
https://codeberg.org/grunfink/snac2.git
synced 2024-11-22 13:25:04 +00:00
Use xs_set_result() in timeline_top_level().
This commit is contained in:
parent
0c525335ee
commit
adfc9217d7
1 changed files with 2 additions and 6 deletions
8
data.c
8
data.c
|
@ -806,7 +806,6 @@ void timeline_admire(snac *snac, char *o_msg, char *id, char *admirer, int like)
|
|||
d_char *timeline_top_level(d_char *list)
|
||||
/* returns the top level md5 entries from this index */
|
||||
{
|
||||
d_char *tl = xs_list_new();
|
||||
xs_set seen;
|
||||
char *p, *v;
|
||||
|
||||
|
@ -833,13 +832,10 @@ d_char *timeline_top_level(d_char *list)
|
|||
strcpy(line, line2);
|
||||
}
|
||||
|
||||
if (xs_set_add(&seen, line) == 1)
|
||||
tl = xs_list_append(tl, line);
|
||||
xs_set_add(&seen, line);
|
||||
}
|
||||
|
||||
xs_set_free(&seen);
|
||||
|
||||
return tl;
|
||||
return xs_set_result(&seen);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue