Diffstat (limited to 'noncore/apps/opie-console/filetransfer.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/apps/opie-console/filetransfer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/noncore/apps/opie-console/filetransfer.cpp b/noncore/apps/opie-console/filetransfer.cpp index 8e86ebb..14787f6 100644 --- a/noncore/apps/opie-console/filetransfer.cpp +++ b/noncore/apps/opie-console/filetransfer.cpp @@ -11,13 +11,13 @@ #include "procctl.h" #include "filetransfer.h" FileTransfer::FileTransfer( Type t, IOLayer* lay ) - : FileTransferLayer( lay ), m_type( t ) { + : FileTransferLayer( lay ), m_type( t ), m_pid ( 0 ) { signal(SIGPIPE, SIG_IGN ); m_not = 0l; m_proc = 0l; } FileTransfer::~FileTransfer() { @@ -232,13 +232,13 @@ void FileTransfer::slotProgress( const QStringList& list ) { m_prog = prog; emit progress(m_file, m_prog, bps, -1, min , sec ); } } void FileTransfer::cancel() { - ::kill(m_pid,9 ); + if(m_pid > 0) ::kill(m_pid,9 ); delete m_not; } void FileTransfer::slotExec() { qWarning("exited!"); char buf[2]; ::read(m_term[0], buf, 1 ); |