diff options
| author | 2023-05-24 13:05:43 +0200 | |
|---|---|---|
| committer | 2023-05-24 13:05:43 +0200 | |
| commit | 5d8e370ec39d8345c95f6f2a5d8b6865b429b8fa (patch) | |
| tree | fd547eed6164d7e0a028ca1ecb3741d83df96cb8 | |
| parent | Polls can now be voted. (diff) | |
| download | penes-snac2-5d8e370ec39d8345c95f6f2a5d8b6865b429b8fa.tar.gz penes-snac2-5d8e370ec39d8345c95f6f2a5d8b6865b429b8fa.tar.xz penes-snac2-5d8e370ec39d8345c95f6f2a5d8b6865b429b8fa.zip | |
More prototype tunnings.
| -rw-r--r-- | data.c | 10 | ||||
| -rw-r--r-- | html.c | 2 | ||||
| -rw-r--r-- | snac.h | 10 |
3 files changed, 11 insertions, 11 deletions
| @@ -482,7 +482,7 @@ int index_len(const char *fn) | |||
| 482 | } | 482 | } |
| 483 | 483 | ||
| 484 | 484 | ||
| 485 | d_char *index_list(const char *fn, int max) | 485 | xs_list *index_list(const char *fn, int max) |
| 486 | /* returns an index as a list */ | 486 | /* returns an index as a list */ |
| 487 | { | 487 | { |
| 488 | d_char *list = NULL; | 488 | d_char *list = NULL; |
| @@ -508,7 +508,7 @@ d_char *index_list(const char *fn, int max) | |||
| 508 | } | 508 | } |
| 509 | 509 | ||
| 510 | 510 | ||
| 511 | d_char *index_list_desc(const char *fn, int skip, int show) | 511 | xs_list *index_list_desc(const char *fn, int skip, int show) |
| 512 | /* returns an index as a list, in reverse order */ | 512 | /* returns an index as a list, in reverse order */ |
| 513 | { | 513 | { |
| 514 | d_char *list = NULL; | 514 | d_char *list = NULL; |
| @@ -768,7 +768,7 @@ int object_announces_len(const char *id) | |||
| 768 | } | 768 | } |
| 769 | 769 | ||
| 770 | 770 | ||
| 771 | d_char *object_children(const char *id) | 771 | xs_list *object_children(const char *id) |
| 772 | /* returns the list of an object's children */ | 772 | /* returns the list of an object's children */ |
| 773 | { | 773 | { |
| 774 | xs *fn = _object_index_fn(id, "_c.idx"); | 774 | xs *fn = _object_index_fn(id, "_c.idx"); |
| @@ -776,14 +776,14 @@ d_char *object_children(const char *id) | |||
| 776 | } | 776 | } |
| 777 | 777 | ||
| 778 | 778 | ||
| 779 | d_char *object_likes(const char *id) | 779 | xs_list *object_likes(const char *id) |
| 780 | { | 780 | { |
| 781 | xs *fn = _object_index_fn(id, "_l.idx"); | 781 | xs *fn = _object_index_fn(id, "_l.idx"); |
| 782 | return index_list(fn, XS_ALL); | 782 | return index_list(fn, XS_ALL); |
| 783 | } | 783 | } |
| 784 | 784 | ||
| 785 | 785 | ||
| 786 | d_char *object_announces(const char *id) | 786 | xs_list *object_announces(const char *id) |
| 787 | { | 787 | { |
| 788 | xs *fn = _object_index_fn(id, "_a.idx"); | 788 | xs *fn = _object_index_fn(id, "_a.idx"); |
| 789 | return index_list(fn, XS_ALL); | 789 | return index_list(fn, XS_ALL); |
| @@ -891,7 +891,7 @@ xs_str *html_entry(snac *snac, xs_str *os, const xs_dict *msg, int local, | |||
| 891 | } | 891 | } |
| 892 | } | 892 | } |
| 893 | 893 | ||
| 894 | if (strcmp(type, "Question") == 0) { | 894 | if (strcmp(type, "Question") == 0) { /** question content **/ |
| 895 | xs_list *oo = xs_dict_get(msg, "oneOf"); | 895 | xs_list *oo = xs_dict_get(msg, "oneOf"); |
| 896 | xs_list *ao = xs_dict_get(msg, "anyOf"); | 896 | xs_list *ao = xs_dict_get(msg, "anyOf"); |
| 897 | xs_list *p; | 897 | xs_list *p; |
| @@ -69,8 +69,8 @@ int index_add(const char *fn, const char *md5); | |||
| 69 | int index_gc(const char *fn); | 69 | int index_gc(const char *fn); |
| 70 | int index_first(const char *fn, char *buf, int size); | 70 | int index_first(const char *fn, char *buf, int size); |
| 71 | int index_len(const char *fn); | 71 | int index_len(const char *fn); |
| 72 | d_char *index_list(const char *fn, int max); | 72 | xs_list *index_list(const char *fn, int max); |
| 73 | d_char *index_list_desc(const char *fn, int skip, int show); | 73 | xs_list *index_list_desc(const char *fn, int skip, int show); |
| 74 | 74 | ||
| 75 | int object_add(const char *id, d_char *obj); | 75 | int object_add(const char *id, d_char *obj); |
| 76 | int object_add_ow(const char *id, d_char *obj); | 76 | int object_add_ow(const char *id, d_char *obj); |
| @@ -88,9 +88,9 @@ int object_unadmire(const char *id, const char *actor, int like); | |||
| 88 | int object_likes_len(const char *id); | 88 | int object_likes_len(const char *id); |
| 89 | int object_announces_len(const char *id); | 89 | int object_announces_len(const char *id); |
| 90 | 90 | ||
| 91 | d_char *object_children(const char *id); | 91 | xs_list *object_children(const char *id); |
| 92 | d_char *object_likes(const char *id); | 92 | xs_list *object_likes(const char *id); |
| 93 | d_char *object_announces(const char *id); | 93 | xs_list *object_announces(const char *id); |
| 94 | int object_parent(const char *id, char *buf, int size); | 94 | int object_parent(const char *id, char *buf, int size); |
| 95 | 95 | ||
| 96 | int object_user_cache_add(snac *snac, const char *id, const char *cachedir); | 96 | int object_user_cache_add(snac *snac, const char *id, const char *cachedir); |