ocaml: Fix memory leak in bindings for functions that return buffers.
authorRichard W.M. Jones <rjones@redhat.com>
Tue, 29 Nov 2011 17:13:17 +0000 (17:13 +0000)
committerRichard W.M. Jones <rjones@redhat.com>
Fri, 2 Dec 2011 08:34:00 +0000 (08:34 +0000)
commitf1ea1ec101df19a16b85a592564a284ebe8e6bf3
tree03afb8ded434721ae89dd2490514fed6d8725369
parenta5680971a941d143dda26bd7ead672de1c3dec41
ocaml: Fix memory leak in bindings for functions that return buffers.

RBufferOut binding didn't free the buffer after copying it onto
the OCaml heap.

Found by valgrind.
(cherry picked from commit 6bd0eec12f2e39360847bfe7a9f50628cc89ed8e)
generator/generator_ocaml.ml