aboutsummaryrefslogtreecommitdiffstats
path: root/sharkd_daemon.c
AgeCommit message (Collapse)AuthorFilesLines
2017-02-12sharkd: fix a memory leak on Windows introduced in gfe06aadPascal Quantin1-0/+1
Change-Id: I907dbc924574b02d2f1b8d7668158b5b6d2c87cf Reviewed-on: https://code.wireshark.org/review/20073 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2017-02-03sharkd: fix warning C4090: 'function' : different 'const' qualifiersPascal Quantin1-2/+4
According to https://msdn.microsoft.com/en-us/library/windows/desktop/ms682425(v=vs.85).aspx the lpCommandLine argument must not be const as is may cause an access violation. Change-Id: Iedd77663cd21ca8df542595890fbc7023f2c9c2b Reviewed-on: https://code.wireshark.org/review/19922 Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-02-01Use INVALID_SOCKET for an invalid socket handle.Guy Harris1-14/+14
-1 is fine on UN*X, but, on Windows, it's INVALID_SOCKET. We define INVALID_SOCKET as (-1) on UN*X, so it can be used on both platforms. Change-Id: Ib2269ddf98c352a1d3c85e44006cc49d80750a78 Reviewed-on: https://code.wireshark.org/review/19909 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-02-01Fix some more UN*X-vs-Windows issues.Guy Harris1-3/+3
Change-Id: Ie9ad31289f0572a7e7249fcb3305849673536f05 Reviewed-on: https://code.wireshark.org/review/19908 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-02-01sharkd: windows supportJakub Zawadzki1-23/+94
Change-Id: I6581bacdea49416cc26431f66b093f36b39c5a67 Reviewed-on: https://code.wireshark.org/review/19829 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-01-26Clean up some UN*X-vs-Windows socket issues.Guy Harris1-22/+3
Have a wsutil/socket.h file, for inclusion by everything that uses sockets, that contains the UN*X-vs-Windows #includes and #defines to hide some UN*X-sockets vs. Winsock API differences. That stuff mostly comes from from extcap/extcap-base.h; have that file just include wsutil/socket.h rather than defining that stuff itself. Include it in sharkd_daemon.c. Use socklen_t for the size of things to pass to bind() as the last argument; wsutil/socket.h defines it as int on Windows. Ignore sharkd in Git. Change-Id: I3f2171b7aa613717f52305f62bfd7d43e0172dc6 Reviewed-on: https://code.wireshark.org/review/19796 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-01-26Fix sharkd compiling on WindowsMichael Mann1-5/+40
Change-Id: I8c614189159f1263d9452d495cee34d1a2c1bfcb Reviewed-on: https://code.wireshark.org/review/19790 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-01-25Add sharkd - daemon variantJakub Zawadzki1-0/+223
sharkd listens on UNIX socket and allows external clients to run commands like: loading file, analysing frames or running TAP(s). Change-Id: I443b2865e4adfd1c11f4f57d09ff7fce6b1e8766 Reviewed-on: https://code.wireshark.org/review/18208 Petri-Dish: Jakub Zawadzki <darkjames-ws@darkjames.pl> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Peter Wu <peter@lekensteyn.nl> Reviewed-by: Jakub Zawadzki <darkjames-ws@darkjames.pl>