Ethereal-dev: [Ethereal-dev] SEGV fix to reassemble.c

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Richard van der Hoff <richardv@xxxxxxxxxxxxx>
Date: Fri, 25 Jun 2004 03:12:27 +0100
Hi all,

At some point in the last few days, reassemble_init() seems to have got broken in CVS such that it segfaults if you try to start a new capture with one already loaded.

The fix is trivial: please find a patch attached.

Cheers

--
Richard van der Hoff <richardv@xxxxxxxxxxxxx>
Systems Analyst
Tel: +44 (0) 845 666 7778
http://www.mxtelecom.com
Index: reassemble.c
===================================================================
RCS file: /cvs/ethereal/reassemble.c,v
retrieving revision 1.1.1.3
retrieving revision 1.2
diff -u -u -r1.1.1.3 -r1.2
--- reassemble.c	24 Jun 2004 23:12:20 -0000	1.1.1.3
+++ reassemble.c	25 Jun 2004 01:45:34 -0000	1.2
@@ -309,7 +309,7 @@
 	if (fragment_key_chunk != NULL)
 		g_mem_chunk_destroy(fragment_key_chunk);
 	if (dcerpc_fragment_key_chunk != NULL)
-		g_mem_chunk_destroy(fragment_key_chunk);
+		g_mem_chunk_destroy(dcerpc_fragment_key_chunk);
 	if (fragment_data_chunk != NULL)
 		g_mem_chunk_destroy(fragment_data_chunk);
 	if (reassembled_key_chunk != NULL)