Closed gvanem closed 5 years ago
Well, there are some confusing bits there.
Closing the pcap_t
is one thing; that should be done when you're done capturing.
But that shouldn't be mixed with finishing up SSL on the control socket; that should be done right before the control socket is closed.
I'll look at cleaning that up.
OK, so I did some cleanups in 5ec780d84809c8be1398f55527ada06f4ec7034e, e6715e9568197af6c1f8ce010c2f4682581db621, and 6271a52c71bc573b243a7016f472bc075bd5cd78.
OK, so I did some cleanups in
Applying all those, it seems very stable. No crashes in _DEBUG
so far.
I experience frequent crashes in
rpcapd.exe
when pressing^C
to stop a windump-client. It seems there is a double call topcap_close()
; last statement indaemon.c
. Thissession_close()
is duplicated in 2 other places (rather messy and confusing).Building everything in
_DEBUG
-mode clearly showsp->opt.device
(inpcap_close()
) is filled with0xDDDD..
at the time of the crash.Doing this patch seems to plug this double-free:
But I fail to understand fully why (?)