fix some memory leak, hook func and streamgraph still leaks