summaryrefslogtreecommitdiff
authormickeyl <mickeyl>2004-05-03 13:50:22 (UTC)
committer mickeyl <mickeyl>2004-05-03 13:50:22 (UTC)
commitaad04cffe30ef133edcd5051ce7e486f27599d83 (patch) (side-by-side diff)
tree830ccec1732ae743073511268c7bb67764c4fb6b
parent9efa98c49988a41de7613f56818f2e31bb24e22b (diff)
downloadopie-aad04cffe30ef133edcd5051ce7e486f27599d83.zip
opie-aad04cffe30ef133edcd5051ce7e486f27599d83.tar.gz
opie-aad04cffe30ef133edcd5051ce7e486f27599d83.tar.bz2
don't always write a capture file
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/net/wellenreiter/gui/mainwindow.cpp2
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiter.cpp10
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiter.h2
3 files changed, 7 insertions, 7 deletions
diff --git a/noncore/net/wellenreiter/gui/mainwindow.cpp b/noncore/net/wellenreiter/gui/mainwindow.cpp
index 8525109..ef7ffcf 100644
--- a/noncore/net/wellenreiter/gui/mainwindow.cpp
+++ b/noncore/net/wellenreiter/gui/mainwindow.cpp
@@ -224,3 +224,3 @@ void WellenreiterMainWindow::changedSniffingState()
- if ( !mw->sniffing )
+ if ( !mw->sniffing && QFile::exists( mw->dumpname ) )
{
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.cpp b/noncore/net/wellenreiter/gui/wellenreiter.cpp
index fe8f22d..2f85790 100644
--- a/noncore/net/wellenreiter/gui/wellenreiter.cpp
+++ b/noncore/net/wellenreiter/gui/wellenreiter.cpp
@@ -115,2 +115,3 @@ void Wellenreiter::signalHandler( int sig )
{
+ Wellenreiter::instance->pcap->closeDumpFile();
Wellenreiter::instance->pcap->close();
@@ -624,6 +625,2 @@ void Wellenreiter::startClicked()
}
- else // write it anyway ;)
- {
- dumpname = "/var/log/dump.wellenreiter";
- }
@@ -634,4 +631,7 @@ void Wellenreiter::startClicked()
- odebug << "Wellenreiter:: dumping to " << dumpname << "" << oendl;
+ if ( configwindow->writeCaptureFile->isChecked() )
+ {
+ odebug << "Wellenreiter:: dumping to " << dumpname << oendl;
pcap->openDumpFile( dumpname );
+ }
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.h b/noncore/net/wellenreiter/gui/wellenreiter.h
index 32e5690..f582a5f 100644
--- a/noncore/net/wellenreiter/gui/wellenreiter.h
+++ b/noncore/net/wellenreiter/gui/wellenreiter.h
@@ -57,2 +57,3 @@ class Wellenreiter : public WellenreiterBase {
public:
+ QString dumpname;
bool sniffing;
@@ -99,3 +100,2 @@ class Wellenreiter : public WellenreiterBase {
- QString dumpname;
Opie::Net::OWirelessNetworkInterface* iface;