author | mickeyl <mickeyl> | 2003-10-28 16:39:26 (UTC) |
---|---|---|
committer | mickeyl <mickeyl> | 2003-10-28 16:39:26 (UTC) |
commit | 5acd7ce51829c317f6218ff059d0d2f63cdb0871 (patch) (unidiff) | |
tree | 8db30d3910ebd8c6936ea4aaa35b03da1faa2f1e | |
parent | 877bc5c756d94db71a745596dd7e48104a2ec9a1 (diff) | |
download | opie-5acd7ce51829c317f6218ff059d0d2f63cdb0871.zip opie-5acd7ce51829c317f6218ff059d0d2f63cdb0871.tar.gz opie-5acd7ce51829c317f6218ff059d0d2f63cdb0871.tar.bz2 |
catch up with API changes in libopienet
-rw-r--r-- | noncore/net/wellenreiter/gui/wellenreiter.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.cpp b/noncore/net/wellenreiter/gui/wellenreiter.cpp index 60bf231..365efb0 100644 --- a/noncore/net/wellenreiter/gui/wellenreiter.cpp +++ b/noncore/net/wellenreiter/gui/wellenreiter.cpp | |||
@@ -379,33 +379,33 @@ void Wellenreiter::stopClicked() | |||
379 | { | 379 | { |
380 | if ( iface ) | 380 | if ( iface ) |
381 | { | 381 | { |
382 | disconnect( SIGNAL( receivedPacket(OPacket*) ), this, SLOT( receivePacket(OPacket*) ) ); | 382 | disconnect( SIGNAL( receivedPacket(OPacket*) ), this, SLOT( receivePacket(OPacket*) ) ); |
383 | disconnect( SIGNAL( hopped(int) ), this, SLOT( channelHopped(int) ) ); | 383 | disconnect( SIGNAL( hopped(int) ), this, SLOT( channelHopped(int) ) ); |
384 | iface->setChannelHopping(); // stop hopping channels | 384 | iface->setChannelHopping(); // stop hopping channels |
385 | } | 385 | } |
386 | else | 386 | else |
387 | killTimers(); | 387 | killTimers(); |
388 | 388 | ||
389 | pcap->close(); | 389 | pcap->close(); |
390 | sniffing = false; | 390 | sniffing = false; |
391 | 391 | ||
392 | if ( iface ) | 392 | if ( iface ) |
393 | { | 393 | { |
394 | // switch off monitor mode | 394 | // switch off monitor mode |
395 | iface->setMonitorMode( false ); | 395 | iface->setMode( "managed" ); |
396 | // switch off promisc flag | 396 | // switch off promisc flag |
397 | iface->setPromiscuousMode( false ); | 397 | iface->setPromiscuousMode( false ); |
398 | 398 | ||
399 | system( "cardctl reset; sleep 1" ); //FIXME: Use OProcess | 399 | system( "cardctl reset; sleep 1" ); //FIXME: Use OProcess |
400 | } | 400 | } |
401 | 401 | ||
402 | logwindow->log( "(i) Stopped Scanning." ); | 402 | logwindow->log( "(i) Stopped Scanning." ); |
403 | assert( parent() ); | 403 | assert( parent() ); |
404 | ( (QMainWindow*) parent() )->setCaption( "Wellenreiter II" ); | 404 | ( (QMainWindow*) parent() )->setCaption( "Wellenreiter II" ); |
405 | 405 | ||
406 | // message the user | 406 | // message the user |
407 | QMessageBox::information( this, "Wellenreiter II", | 407 | QMessageBox::information( this, "Wellenreiter II", |
408 | tr( "Your wireless card\nshould now be usable again." ) ); | 408 | tr( "Your wireless card\nshould now be usable again." ) ); |
409 | 409 | ||
410 | sniffing = false; | 410 | sniffing = false; |
411 | emit( stoppedSniffing() ); | 411 | emit( stoppedSniffing() ); |
@@ -463,34 +463,34 @@ void Wellenreiter::startClicked() | |||
463 | 463 | ||
464 | switch ( cardtype ) | 464 | switch ( cardtype ) |
465 | { | 465 | { |
466 | case DEVTYPE_CISCO: iface->setMonitoring( new OCiscoMonitoringInterface( iface, usePrism ) ); break; | 466 | case DEVTYPE_CISCO: iface->setMonitoring( new OCiscoMonitoringInterface( iface, usePrism ) ); break; |
467 | case DEVTYPE_WLAN_NG: iface->setMonitoring( new OWlanNGMonitoringInterface( iface, usePrism ) ); break; | 467 | case DEVTYPE_WLAN_NG: iface->setMonitoring( new OWlanNGMonitoringInterface( iface, usePrism ) ); break; |
468 | case DEVTYPE_HOSTAP: iface->setMonitoring( new OHostAPMonitoringInterface( iface, usePrism ) ); break; | 468 | case DEVTYPE_HOSTAP: iface->setMonitoring( new OHostAPMonitoringInterface( iface, usePrism ) ); break; |
469 | case DEVTYPE_ORINOCO: iface->setMonitoring( new OOrinocoMonitoringInterface( iface, usePrism ) ); break; | 469 | case DEVTYPE_ORINOCO: iface->setMonitoring( new OOrinocoMonitoringInterface( iface, usePrism ) ); break; |
470 | case DEVTYPE_MANUAL: QMessageBox::information( this, "Wellenreiter II", tr( "Bring your device into\nmonitor mode now." ) ); break; | 470 | case DEVTYPE_MANUAL: QMessageBox::information( this, "Wellenreiter II", tr( "Bring your device into\nmonitor mode now." ) ); break; |
471 | case DEVTYPE_FILE: qDebug( "Wellenreiter: Capturing from file '%s'", (const char*) interface ); break; | 471 | case DEVTYPE_FILE: qDebug( "Wellenreiter: Capturing from file '%s'", (const char*) interface ); break; |
472 | default: assert( 0 ); // shouldn't reach this | 472 | default: assert( 0 ); // shouldn't reach this |
473 | } | 473 | } |
474 | 474 | ||
475 | // switch device into monitor mode | 475 | // switch device into monitor mode |
476 | if ( cardtype < DEVTYPE_FILE ) | 476 | if ( cardtype < DEVTYPE_FILE ) |
477 | { | 477 | { |
478 | if ( cardtype != DEVTYPE_MANUAL ) | 478 | if ( cardtype != DEVTYPE_MANUAL ) |
479 | iface->setMonitorMode( true ); | 479 | iface->setMode( "monitor" ); |
480 | if ( !iface->monitorMode() ) | 480 | if ( iface->mode() != "monitor" ) |
481 | { | 481 | { |
482 | if ( QMessageBox::warning( this, "Wellenreiter II", | 482 | if ( QMessageBox::warning( this, "Wellenreiter II", |
483 | tr( "Can't set interface '%1'\ninto monitor mode:\n" ).arg( iface->name() ) + strerror( errno ) + | 483 | tr( "Can't set interface '%1'\ninto monitor mode:\n" ).arg( iface->name() ) + strerror( errno ) + |
484 | tr( "\nContinue with limited functionality?" ), QMessageBox::Yes, QMessageBox::No ) == QMessageBox::No ) | 484 | tr( "\nContinue with limited functionality?" ), QMessageBox::Yes, QMessageBox::No ) == QMessageBox::No ) |
485 | return; | 485 | return; |
486 | } | 486 | } |
487 | } | 487 | } |
488 | 488 | ||
489 | // open GPS device | 489 | // open GPS device |
490 | if ( configwindow->enableGPS->isChecked() ) | 490 | if ( configwindow->enableGPS->isChecked() ) |
491 | { | 491 | { |
492 | qDebug( "Wellenreiter:GPS enabled @ %s:%d", (const char*) configwindow->gpsdHost->currentText(), configwindow->gpsdPort->value() ); | 492 | qDebug( "Wellenreiter:GPS enabled @ %s:%d", (const char*) configwindow->gpsdHost->currentText(), configwindow->gpsdPort->value() ); |
493 | gps->open( configwindow->gpsdHost->currentText(), configwindow->gpsdPort->value() ); | 493 | gps->open( configwindow->gpsdHost->currentText(), configwindow->gpsdPort->value() ); |
494 | } | 494 | } |
495 | 495 | ||
496 | // open pcap and start sniffing | 496 | // open pcap and start sniffing |