summaryrefslogtreecommitdiff
path: root/mastoapi.c
diff options
context:
space:
mode:
authorGravatar grunfink2025-12-09 05:01:06 +0100
committerGravatar grunfink2025-12-09 05:01:06 +0100
commita8b706b193d8d22191fa85ac290b90491be54ee3 (patch)
tree0b8f42be2fa1b328b6e451d90addaa99e7abd536 /mastoapi.c
parentmake webpush use our notification server vkey instead of a random, ill-formated (diff)
downloadsnac2-a8b706b193d8d22191fa85ac290b90491be54ee3.tar.gz
snac2-a8b706b193d8d22191fa85ac290b90491be54ee3.tar.xz
snac2-a8b706b193d8d22191fa85ac290b90491be54ee3.zip
Fixed small memory leak.
Diffstat (limited to 'mastoapi.c')
-rw-r--r--mastoapi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mastoapi.c b/mastoapi.c
index 9aa29d8..9503447 100644
--- a/mastoapi.c
+++ b/mastoapi.c
@@ -3044,7 +3044,7 @@ int mastoapi_post_handler(const xs_dict *req, const char *q_path,
3044 xs *app = xs_dict_new(); 3044 xs *app = xs_dict_new();
3045 xs *id = xs_replace_i(tid(0), ".", ""); 3045 xs *id = xs_replace_i(tid(0), ".", "");
3046 xs *csec = random_str(); 3046 xs *csec = random_str();
3047 char *vkey = (char *)xs_dict_get(srv_config, "vkey"); 3047 xs *vkey = xs_dup(xs_dict_get(srv_config, "vkey"));
3048 if (vkey == NULL) 3048 if (vkey == NULL)
3049 vkey = random_str(); 3049 vkey = random_str();
3050 3050