diff options
| author | byte <gf3qyrmw7@mozmail.com> | 2026-01-17 02:49:56 +0000 |
|---|---|---|
| committer | byte <gf3qyrmw7@mozmail.com> | 2026-01-17 02:49:56 +0000 |
| commit | 84c0ee63cf4a67e7fb8484ef874b121160b63382 (patch) | |
| tree | 3de92286d5b2f4ae42ac6ba595950688e2e71484 | |
| parent | 5a437c0f1d1e2f590a177e0eb7e13c05958ede4d (diff) | |
segfault fix
| -rw-r--r-- | html.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -167,6 +167,7 @@ xs_str *actor_pronouns(xs_dict *actor) { const xs_list *attachment; const xs_dict *d; + const char *v; const char *pronouns = ""; xs_str *ret; @@ -175,7 +176,9 @@ xs_str *actor_pronouns(xs_dict *actor) xs *prop = xs_utf8_to_lower(xs_dict_get(d, "name")); /* make sure that we are reading the correct metadata */ if (strlen(prop) == 8 && strcmp(prop, "pronouns") == 0) { - pronouns = xs_dict_get(d, "value"); + /* safeguard from NULL values */ + v = xs_dict_get(d, "value"); + pronouns = v ? v : pronouns; break; } } |