diff options
author | Ivan Nardi <12729895+IvanNardi@users.noreply.github.com> | 2021-02-10 15:24:34 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-10 15:24:34 +0100 |
commit | 421609475ef8d99d92ca18bef900bf13058b2b06 (patch) | |
tree | 3b6a3e03acf3a7a623fe875a9e30e70d05bbe460 | |
parent | 1e12c90c66c6ea720fd87e2dca61e0d15a38ca3a (diff) |
Fix small memory leak (#1133)
Now function definition matches the prototype in ndpi_api.h.in
-rw-r--r-- | example/ndpiReader.c | 2 | ||||
-rw-r--r-- | src/lib/ndpi_analyze.c | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/example/ndpiReader.c b/example/ndpiReader.c index a2caeaad9..7681d1627 100644 --- a/example/ndpiReader.c +++ b/example/ndpiReader.c @@ -3780,6 +3780,8 @@ void jitterUnitTest() { if(trace) printf("%2u)\t%.3f\t%.3f\n", i, v[i], rc); } + + ndpi_jitter_free(&jitter); } /* *********************************************** */ diff --git a/src/lib/ndpi_analyze.c b/src/lib/ndpi_analyze.c index 2f21dde78..77400afd3 100644 --- a/src/lib/ndpi_analyze.c +++ b/src/lib/ndpi_analyze.c @@ -1085,7 +1085,7 @@ int ndpi_jitter_init(struct ndpi_jitter_struct *s, u_int16_t num_learning_values /* ************************************* */ -void ndpi_free_jitter(struct ndpi_jitter_struct *s) { +void ndpi_jitter_free(struct ndpi_jitter_struct *s) { ndpi_free(s->observations); } |