(trunk libT) fix a minor memory leak in the bencode regression tests.
Found by llvm's static analyzer. This is a minor issue since the leak is in an automated test rather than in shipping code, but it's still better to fix it.
This commit is contained in:
parent
0d13057111
commit
f9cc51f0d3
|
@ -319,8 +319,8 @@ testJSONSnippet( const char * benc_str,
|
|||
const char * expected )
|
||||
{
|
||||
tr_benc top;
|
||||
struct evbuffer * buf = evbuffer_new( );
|
||||
char * serialized;
|
||||
struct evbuffer * buf;
|
||||
|
||||
tr_bencLoad( benc_str, strlen( benc_str ), &top, NULL );
|
||||
buf = tr_bencToBuf( &top, TR_FMT_JSON );
|
||||
|
|
Loading…
Reference in New Issue