Browse Source

Merge pull request 'Fixed another small leak' (#589) from dandelions/snac2:pr-leak-mastoapi-2 into master

Reviewed-on: https://codeberg.org/grunfink/snac2/pulls/589
grunfink 4 months ago
parent
commit
82b56317fc
1 changed files with 1 additions and 0 deletions
  1. 1 0
      mastoapi.c

+ 1 - 0
mastoapi.c

@@ -3205,6 +3205,7 @@ int mastoapi_post_handler(const xs_dict *req, const char *q_path,
 
         /* Ice Cubes sends these values as query parameters, so try these */
         if (name == NULL && ruri == NULL && scope == NULL) {
+            xs_free(args);
             args = xs_dup(xs_dict_get(req, "q_vars"));
             name  = xs_dict_get(args, "client_name");
             ruri  = xs_dict_get(args, "redirect_uris");