aboutsummaryrefslogtreecommitdiff
path: root/lib/leak-checker.c
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2011-02-23 10:31:41 -0800
committerBen Pfaff <blp@nicira.com>2011-02-23 15:14:42 -0800
commit93e039fb5e7ae77a556e1d144ca069a86555598b (patch)
treedde44473423eebf9f49607b1a2494dc9327703db /lib/leak-checker.c
parentc55acc2eed76ae17667fa5f65f5f3c347b796926 (diff)
leak-checker: Avoid printing freed pointer.
I think that this will work OK, and it should avoid complaints from static checkers about using a freed pointer. Coverity #11069.
Diffstat (limited to 'lib/leak-checker.c')
-rw-r--r--lib/leak-checker.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/leak-checker.c b/lib/leak-checker.c
index 8b781824..42b3818a 100644
--- a/lib/leak-checker.c
+++ b/lib/leak-checker.c
@@ -216,11 +216,10 @@ hook_free(void *p, const void *caller OVS_UNUSED)
}
set_hooks(&libc_hooks);
+ log_callers("free(%p)", p);
free(p);
get_hooks(&libc_hooks);
- log_callers("free(%p)", p);
-
reset_hooks();
}