1
0
mirror of https://github.com/mfontanini/libtins synced 2026-01-25 11:41:35 +01:00

Added 1000ms as the default read timeout used when calling pcap_open_live. Added BaseSniffer::set_timeout to modify this parameter.

This commit is contained in:
Matias Fontanini
2013-11-19 20:51:58 -03:00
parent 6355aff3cd
commit 295ebb679c
2 changed files with 13 additions and 1 deletions

View File

@@ -192,6 +192,14 @@ namespace Tins {
*/
int get_fd();
/**
* \brief Sets the read timeout for this sniffer.
*
* This calls pcap_set_timeout using the provided parameter.
* \param ms The amount of milliseconds.
*/
void set_timeout(int ms);
/**
* \brief Retrieves this sniffer's link type.
*