]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
schedule: Fix potential memory-leak (#4510)
authorJorge Pereira <jpereira@users.noreply.github.com>
Mon, 16 May 2022 18:59:48 +0000 (15:59 -0300)
committerGitHub <noreply@github.com>
Mon, 16 May 2022 18:59:48 +0000 (14:59 -0400)
src/lib/io/schedule.c

index 47543c2e66352833da65bf14c3b14dcaf3b43195..423fc7a4ba07802f4b02822d270a417a823a16a3 100644 (file)
@@ -267,6 +267,8 @@ fail:
         */
        sem_post(&sc->worker_sem);
 
+       talloc_free(ctx);
+
        return NULL;
 }
 
@@ -350,6 +352,8 @@ fail:
         */
        sem_post(&sc->network_sem);
 
+       talloc_free(ctx);
+
        return NULL;
 }