[Freeswitch-svn] [commit] r12068 - freeswitch/trunk/src
FreeSWITCH SVN
anthm at freeswitch.org
Mon Feb 16 12:25:05 PST 2009
Author: anthm
Date: Mon Feb 16 14:25:05 2009
New Revision: 12068
Log:
remove leak
Modified:
freeswitch/trunk/src/switch_cpp.cpp
Modified: freeswitch/trunk/src/switch_cpp.cpp
==============================================================================
--- freeswitch/trunk/src/switch_cpp.cpp (original)
+++ freeswitch/trunk/src/switch_cpp.cpp Mon Feb 16 14:25:05 2009
@@ -270,7 +270,9 @@
}
} else {
if (switch_event_serialize(event, &serialized_string, SWITCH_TRUE) == SWITCH_STATUS_SUCCESS) {
- serialized_string = switch_mprintf("'%s'", serialized_string);
+ char *new_serialized_string = switch_mprintf("'%s'", serialized_string);
+ free(serialized_string);
+ serialized_string = new_serialized_string;
return serialized_string;
}
}
More information about the Freeswitch-svn
mailing list