From: Tobias Mueller Date: Thu, 13 Jan 2011 15:51:01 +0000 (+0100) Subject: fixup: make pcap read from the file X-Git-Url: http://git.maemo.org/git/?p=pwnitter;a=commitdiff_plain;h=6cc1ab74cfd3c4a97c8a49722b52941c8f28ff8d;ds=sidebyside fixup: make pcap read from the file --- diff --git a/pwnitter.py b/pwnitter.py index 6995b0a..6b176f1 100755 --- a/pwnitter.py +++ b/pwnitter.py @@ -41,9 +41,11 @@ class Pwnitter(dbus.service.Object): in_signature='', out_signature='') def Start(self, filename=None): # FIXME: Prevent double Start() - device = self.device if filename is None: # Then we do *not* want to read from a PCap file but rather a monitor device self.setup_monitor(device) + device = self.device + else: # We have given a filename, so let's make PCap read from the file + device = filename self.is_running = True try: self.cap = pcap.pcap(device)