Free lookup_path memory when benchmarking in mmdblookup
@@ -58,9 +58,10 @@ int main(int argc, char **argv)
if (0 == iterations) {
exit(lookup_and_print(&mmdb, ip_address, lookup_path,
lookup_path_length));
- } else {
- exit(benchmark(&mmdb, iterations));
}
+
+ free(lookup_path);
+ exit(benchmark(&mmdb, iterations));
}
LOCAL void usage(char *program, int exit_code, const char *error)
