Displaying 2 results from an estimated 2 matches for "b598ad3".
2020 Sep 07
0
[libnbd PATCH 2/2] generator: Free closures on failure
...BACK (%s_callback);\n" cbname
+ | OFlags _ -> ()
+ ) optargs;
if is_locked then (
pr " if (h->public_state != get_next_state (h))\n";
pr " h->public_state = get_next_state (h);\n";
diff --git a/lib/debug.c b/lib/debug.c
index 1b503d9..b598ad3 100644
--- a/lib/debug.c
+++ b/lib/debug.c
@@ -54,6 +54,7 @@ nbd_unlocked_set_debug_callback (struct nbd_handle *h,
nbd_unlocked_clear_debug_callback (h);
h->debug_callback = *debug_callback;
+ SET_CALLBACK_TO_NULL (*debug_callback);
return 0;
}
diff --git a/lib/opt.c b/lib/opt.c
in...
2020 Sep 07
4
[libnbd PATCH 0/2] Fix memory leak with closures
As promised in my earlier thread on libnbd completion callback question.
Eric Blake (2):
generator: Refactor handling of closures in unlocked functions
generator: Free closures on failure
docs/libnbd.pod | 2 +-
generator/C.ml | 48 +++++++++++------
generator/C.mli | 1 +
lib/debug.c | 7 +--
lib/opt.c | 31 ++++++-----