Skip to content
Snippets Groups Projects
Commit 97c926f9 authored by Romain CARNUS's avatar Romain CARNUS
Browse files

Fixed a bug in the sendrecv method when using multithreading

parent 5b5bd119
No related branches found
No related tags found
No related merge requests found
...@@ -10,7 +10,7 @@ Functions to send and receive packets. ...@@ -10,7 +10,7 @@ Functions to send and receive packets.
import errno import errno
import cPickle,os,sys,time,subprocess import cPickle,os,sys,time,subprocess
import itertools import itertools
from select import select from select import select,error
from scapy.data import * from scapy.data import *
from scapy import arch from scapy import arch
from scapy.config import conf from scapy.config import conf
...@@ -132,6 +132,8 @@ def sndrcv(pks, pkt, timeout = None, inter = 0, verbose=None, chainCC=0, retry=0 ...@@ -132,6 +132,8 @@ def sndrcv(pks, pkt, timeout = None, inter = 0, verbose=None, chainCC=0, retry=0
inp = [] inp = []
try: try:
inp, out, err = select(inmask,[],[], remaintime) inp, out, err = select(inmask,[],[], remaintime)
except error as e:
continue
except IOError, exc: except IOError, exc:
if exc.errno != errno.EINTR: if exc.errno != errno.EINTR:
raise raise
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment