-rw-r--r-- | noncore/net/opietooth/lib/device.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/noncore/net/opietooth/lib/device.cc b/noncore/net/opietooth/lib/device.cc index 2f04d46..88d4cf9 100644 --- a/noncore/net/opietooth/lib/device.cc +++ b/noncore/net/opietooth/lib/device.cc @@ -125,9 +125,10 @@ void Device::slotExited( OProcess* proc) // and call hciconfig hci0 up // FIXME hardcoded to hci0 now :( m_hci = new OProcess( ); *m_hci << "hciconfig"; - *m_hci << "hci0 up"; + *m_hci << "hci0"; + *m_hci << "up"; connect(m_hci, SIGNAL( processExited(Opie::Core::OProcess*) ), this, SLOT( slotExited(Opie::Core::OProcess* ) ) ); if(!m_hci->start() ){ owarn << "could not start" << oendl; @@ -150,8 +151,10 @@ void Device::slotExited( OProcess* proc) int ret = m_hci->exitStatus(); if( ret == 0 ){ owarn << "attached really really attached" << oendl; m_attached = true; + //Wait for a device to be brought up + ::sleep(1); emit device("hci0", true ); }else{ owarn << "failed" << oendl; emit device("hci0", false ); |