summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--core/qws/qcopbridge.cpp18
-rw-r--r--core/qws/transferserver.cpp82
2 files changed, 54 insertions, 46 deletions
diff --git a/core/qws/qcopbridge.cpp b/core/qws/qcopbridge.cpp
index 4fd0807..822efb7 100644
--- a/core/qws/qcopbridge.cpp
+++ b/core/qws/qcopbridge.cpp
@@ -12,54 +12,58 @@
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** See http://www.trolltech.com/gpl/ for GPL licensing information.
**
** Contact info@trolltech.com if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
#include "qcopbridge.h"
#include "transferserver.h"
+/* OPIE */
#include <qpe/qcopenvelope_qws.h>
#include <qpe/qpeapplication.h>
#include <qpe/version.h>
+#include <opie2/odebug.h>
+/* QT */
#include <qtextstream.h>
#ifdef QWS
#include <qcopchannel_qws.h>
#endif
+/* STD */
#define _XOPEN_SOURCE
#include <pwd.h>
#include <sys/types.h>
#include <unistd.h>
#if defined(_OS_LINUX_)
#include <shadow.h>
#endif
//#define INSECURE
const int block_size = 51200;
QCopBridge::QCopBridge( Q_UINT16 port, QObject *parent ,
const char* name )
: QServerSocket( port, 1, parent, name ),
desktopChannel( 0 ),
cardChannel( 0 )
{
if ( !ok() )
- qWarning( "Failed to bind to port %d", port );
+ owarn << "Failed to bind to port " << port << "" << oendl;
else {
#ifndef QT_NO_COP
desktopChannel = new QCopChannel( "QPE/Desktop", this );
connect( desktopChannel, SIGNAL(received(const QCString&,const QByteArray&)),
this, SLOT(desktopMessage(const QCString&,const QByteArray&)) );
cardChannel = new QCopChannel( "QPE/Card", this );
connect( cardChannel, SIGNAL(received(const QCString&,const QByteArray&)),
this, SLOT(desktopMessage(const QCString&,const QByteArray&)) );
#endif
}
sendSync = FALSE;
}
@@ -101,31 +105,31 @@ void QCopBridge::closeOpenConnections()
QCopBridgePI *pi;
for ( pi = openConnections.first(); pi != 0; pi = openConnections.next() )
pi->close();
}
void QCopBridge::desktopMessage( const QCString &command, const QByteArray &args )
{
command.stripWhiteSpace();
int paren = command.find( "(" );
if ( paren <= 0 ) {
- qDebug("DesktopMessage: bad qcop syntax");
+ odebug << "DesktopMessage: bad qcop syntax" << oendl;
return;
}
QString params = command.mid( paren + 1 );
if ( params[params.length()-1] != ')' ) {
- qDebug("DesktopMessage: bad qcop syntax");
+ odebug << "DesktopMessage: bad qcop syntax" << oendl;
return;
}
params.truncate( params.length()-1 );
QStringList paramList = QStringList::split( ",", params );
QString data;
if ( paramList.count() ) {
QDataStream stream( args, IO_ReadOnly );
for ( QStringList::Iterator it = paramList.begin(); it != paramList.end(); ++it ) {
QString str;
if ( *it == "QString" ) {
@@ -134,25 +138,25 @@ void QCopBridge::desktopMessage( const QCString &command, const QByteArray &args
QCString cstr;
stream >> cstr;
str = QString::fromLocal8Bit( cstr );
} else if ( *it == "int" ) {
int i;
stream >> i;
str = QString::number( i );
} else if ( *it == "bool" ) {
int i;
stream >> i;
str = QString::number( i );
} else {
- qDebug(" cannot route the argument type %s throught the qcop bridge", (*it).latin1() );
+ odebug << " cannot route the argument type " << (*it) << " throught the qcop bridge" << oendl;
return;
}
QString estr;
for (int i=0; i<(int)str.length(); i++) {
QChar ch = str[i];
if ( ch.row() )
goto quick;
switch (ch.cell()) {
case '&':
estr.append( "&amp;" );
break;
case ' ':
@@ -226,51 +230,51 @@ QCopBridgePI::QCopBridgePI( int socket, QObject *parent , const char* name )
}
}
QCopBridgePI::~QCopBridgePI()
{
}
void QCopBridgePI::connectionClosed()
{
emit connectionClosed( this );
- // qDebug( "Debug: Connection closed" );
+ // odebug << "Debug: Connection closed" << oendl;
delete this;
}
void QCopBridgePI::sendDesktopMessage( const QString &msg )
{
QString str = "CALL QPE/Desktop " + msg;
send ( str );
}
void QCopBridgePI::send( const QString& msg )
{
QTextStream os( this );
os << msg << endl;
- //qDebug( "sending qcop message: %s", msg.latin1() );
+ //odebug << "sending qcop message: " << msg << "" << oendl;
}
void QCopBridgePI::read()
{
while ( canReadLine() )
process( readLine().stripWhiteSpace() );
}
void QCopBridgePI::process( const QString& message )
{
- //qDebug( "Command: %s", message.latin1() );
+ //odebug << "Command: " << message << "" << oendl;
// split message using "," as separator
QStringList msg = QStringList::split( " ", message );
if ( msg.isEmpty() ) return;
// command token
QString cmd = msg[0].upper();
// argument token
QString arg;
if ( msg.count() >= 2 )
arg = msg[1];
diff --git a/core/qws/transferserver.cpp b/core/qws/transferserver.cpp
index d0fec89..777c384 100644
--- a/core/qws/transferserver.cpp
+++ b/core/qws/transferserver.cpp
@@ -8,24 +8,28 @@
** Foundation and appearing in the file LICENSE.GPL included in the
** packaging of this file.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** See http://www.trolltech.com/gpl/ for GPL licensing information.
**
** Contact info@trolltech.com if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
+
+/* OPIE */
+#include <opie2/odebug.h>
+
#define _XOPEN_SOURCE
#include <pwd.h>
#include <sys/types.h>
#include <unistd.h>
#include <stdlib.h>
#include <time.h>
#ifndef Q_OS_MACX
#include <shadow.h>
#endif /* Q_OS_MACX */
/* we need the _OS_LINUX stuff first ! */
@@ -65,25 +69,25 @@ extern "C"
#include "transferserver.h"
#include <opie2/oprocess.h>
using namespace Opie::Core;
const int block_size = 51200;
TransferServer::TransferServer( Q_UINT16 port, QObject *parent ,
const char* name )
: QServerSocket( port, 1, parent, name )
{
if ( !ok() )
- qWarning( "Failed to bind to port %d", port );
+ owarn << "Failed to bind to port " << port << "" << oendl;
}
TransferServer::~TransferServer()
{
}
void TransferServer::newConnection( int socket )
{
(void) new ServerPI( socket, this );
}
/*
@@ -308,33 +312,33 @@ ServerPI::ServerPI( int socket, QObject *parent , const char* name )
}
connect( serversocket, SIGNAL( newIncomming(int) ),
SLOT( newConnection(int) ) );
}
}
ServerPI::~ServerPI()
{
}
void ServerPI::connectionClosed()
{
- // qDebug( "Debug: Connection closed" );
+ // odebug << "Debug: Connection closed" << oendl;
delete this;
}
void ServerPI::send( const QString& msg )
{
QTextStream os( this );
os << msg << endl;
- //qDebug( "Reply: %s", msg.latin1() );
+ //odebug << "Reply: " << msg << "" << oendl;
}
void ServerPI::read()
{
while ( canReadLine() )
process( readLine().stripWhiteSpace() );
}
bool ServerPI::checkReadFile( const QString& file )
{
QString filename;
@@ -357,50 +361,50 @@ bool ServerPI::checkWriteFile( const QString& file )
filename = file;
QFileInfo fi( filename );
if ( fi.exists() )
if ( !QFile( filename ).remove() )
return FALSE;
return TRUE;
}
void ServerPI::process( const QString& message )
{
- //qDebug( "Command: %s", message.latin1() );
+ //odebug << "Command: " << message << "" << oendl;
// split message using "," as separator
QStringList msg = QStringList::split( " ", message );
if ( msg.isEmpty() )
return ;
// command token
QString cmd = msg[0].upper();
// argument token
QString arg;
if ( msg.count() >= 2 )
arg = msg[1];
// full argument string
QString args;
if ( msg.count() >= 2 ) {
QStringList copy( msg );
// FIXME: for Qt3
// copy.pop_front()
copy.remove( copy.begin() );
args = copy.join( " " );
}
- //qDebug( "args: %s", args.latin1() );
+ //odebug << "args: " << args << "" << oendl;
// we always respond to QUIT, regardless of state
if ( cmd == "QUIT" ) {
send( "211 Good bye!" );
delete this;
return ;
}
// connected to client
if ( Connected == state )
return ;
@@ -518,25 +522,25 @@ void ServerPI::process( const QString& message )
// FTP SERVICE COMMANDS
// retrieve (RETR)
else if ( cmd == "RETR" )
if ( !args.isEmpty() && checkReadFile( absFilePath( args ) )
|| backupRestoreGzip( absFilePath( args ) ) ) {
send( "150 File status okay" );
sendFile( absFilePath( args ) );
}
else {
- qDebug("550 Requested action not taken");
+ odebug << "550 Requested action not taken" << oendl;
send( "550 Requested action not taken" );
}
// store (STOR)
else if ( cmd == "STOR" )
if ( !args.isEmpty() && checkWriteFile( absFilePath( args ) ) ) {
send( "150 File status okay" );
retrieveFile( absFilePath( args ) );
}
else
send( "550 Requested action not taken" );
@@ -624,25 +628,25 @@ void ServerPI::process( const QString& message )
else {
QDir dir;
if ( dir.rmdir( absFilePath( args ), TRUE ) )
send( "250 Requested file action okay, completed" );
else
send( "550 Requested action not taken" );
}
}
// make directory (MKD)
else if ( cmd == "MKD" ) {
if ( args.isEmpty() ) {
- qDebug(" Error: no arg");
+ odebug << " Error: no arg" << oendl;
send( "500 Syntax error, command unrecognized" );
}
else {
QDir dir;
if ( dir.mkdir( absFilePath( args ), TRUE ) )
send( "250 Requested file action okay, completed." );
else
send( "550 Requested action not taken" );
}
}
// print working directory (PWD)
@@ -664,33 +668,33 @@ void ServerPI::process( const QString& message )
QFileInfo fi( filePath );
bool gzipfile = backupRestoreGzip( filePath );
if ( !fi.exists() && !gzipfile )
send( "500 Syntax error, command unrecognized" );
else {
if ( !gzipfile )
send( "213 " + QString::number( fi.size() ) );
else {
Process duproc( QString("du") );
duproc.addArgument("-s");
QString in, out;
if ( !duproc.exec(in, out) ) {
- qDebug("du process failed; just sending back 1K");
+ odebug << "du process failed; just sending back 1K" << oendl;
send( "213 1024");
}
else {
QString size = out.left( out.find("\t") );
int guess = size.toInt() / 5;
if ( filePath.contains("doc") )
guess *= 1000;
- qDebug("sending back gzip guess of %d", guess);
+ odebug << "sending back gzip guess of " << guess << "" << oendl;
send( "213 " + QString::number(guess) );
}
}
}
}
// name list (NLST)
else if ( cmd == "NLST" ) {
send( "502 Command not implemented" );
}
// site parameters (SITE)
else if ( cmd == "SITE" ) {
@@ -727,26 +731,26 @@ void ServerPI::process( const QString& message )
bool ServerPI::backupRestoreGzip( const QString &file )
{
return (file.find( "backup" ) != -1 &&
file.findRev( ".tgz" ) == (int)file.length() - 4 );
}
bool ServerPI::backupRestoreGzip( const QString &file, QStringList &targets )
{
if ( file.find( "backup" ) != -1 &&
file.findRev( ".tgz" ) == (int)file.length() - 4 ) {
QFileInfo info( file );
targets = info.dirPath( TRUE );
- qDebug("ServerPI::backupRestoreGzip for %s = %s", file.latin1(),
- targets.join(" ").latin1() );
+ odebug << "ServerPI::backupRestoreGzip for " << file.latin1() << " = "
+ << targets.join(" ").latin1() << oendl;
return true;
}
return false;
}
void ServerPI::sendFile( const QString& file )
{
if ( passiv ) {
wait[SendFile] = TRUE;
waitfile = file;
if ( waitsocket )
newConnection( waitsocket );
@@ -975,51 +979,51 @@ QString ServerPI::permissionString( QFileInfo *info )
else
s += "-";
if ( info->permission( QFileInfo::ExeOther ) )
s += "x";
else
s += "-";
return s;
}
void ServerPI::newConnection( int socket )
{
- //qDebug( "New incomming connection" );
+ //odebug << "New incomming connection" << oendl;
if ( !passiv )
return ;
if ( wait[SendFile] ) {
QStringList targets;
if ( backupRestoreGzip( waitfile, targets ) )
dtp->sendGzipFile( waitfile, targets );
else
dtp->sendFile( waitfile );
dtp->setSocket( socket );
}
else if ( wait[RetrieveFile] ) {
- qDebug("check retrieve file");
+ odebug << "check retrieve file" << oendl;
if ( backupRestoreGzip( waitfile ) )
dtp->retrieveGzipFile( waitfile );
else
dtp->retrieveFile( waitfile );
dtp->setSocket( socket );
}
else if ( wait[SendByteArray] ) {
dtp->sendByteArray( waitarray );
dtp->setSocket( socket );
}
else if ( wait[RetrieveByteArray] ) {
- qDebug("retrieve byte array");
+ odebug << "retrieve byte array" << oendl;
dtp->retrieveByteArray();
dtp->setSocket( socket );
}
else
waitsocket = socket;
for ( int i = 0; i < 4; i++ )
wait[i] = FALSE;
}
QString ServerPI::absFilePath( const QString& file )
{
@@ -1066,249 +1070,249 @@ ServerDTP::ServerDTP( QObject *parent, const char* name)
SLOT( extractTarDone() ) );
}
ServerDTP::~ServerDTP()
{
buf.close();
file.close();
createTargzProc->kill();
}
void ServerDTP::extractTarDone()
{
- qDebug("extract done");
+ odebug << "extract done" << oendl;
#ifndef QT_NO_COP
QCopEnvelope e( "QPE/Desktop", "restoreDone(QString)" );
e << file.name();
#endif
}
void ServerDTP::connected()
{
// send file mode
switch ( mode ) {
case SendFile :
if ( !file.exists() || !file.open( IO_ReadOnly) ) {
emit failed();
mode = Idle;
return ;
}
- //qDebug( "Debug: Sending file '%s'", file.name().latin1() );
+ //odebug << "Debug: Sending file '" << file.name() << "'" << oendl;
bytes_written = 0;
if ( file.size() == 0 ) {
//make sure it doesn't hang on empty files
file.close();
emit completed();
mode = Idle;
}
else {
if ( !file.atEnd() ) {
QCString s;
s.resize( block_size );
int bytes = file.readBlock( s.data(), block_size );
writeBlock( s.data(), bytes );
}
}
break;
case SendGzipFile:
if ( createTargzProc->isRunning() ) {
// SHOULDN'T GET HERE, BUT DOING A SAFETY CHECK ANYWAY
- qWarning("Previous tar --gzip process is still running; killing it...");
+ owarn << "Previous tar --gzip process is still running; killing it..." << oendl;
createTargzProc->kill();
}
bytes_written = 0;
- qDebug("==>start send tar process");
+ odebug << "==>start send tar process" << oendl;
if ( !createTargzProc->start(Opie::Core::OProcess::NotifyOnExit, Opie::Core::OProcess::Stdout) )
qWarning("Error starting %s or %s",
createTargzProc->args()[0].data(),
gzipProc->args()[0].data());
break;
case SendBuffer:
if ( !buf.open( IO_ReadOnly) ) {
emit failed();
mode = Idle;
return ;
}
- // qDebug( "Debug: Sending byte array" );
+ // odebug << "Debug: Sending byte array" << oendl;
bytes_written = 0;
while ( !buf.atEnd() )
putch( buf.getch() );
buf.close();
break;
case RetrieveFile:
// retrieve file mode
if ( file.exists() && !file.remove() ) {
emit failed();
mode = Idle;
return ;
}
if ( !file.open( IO_WriteOnly) ) {
emit failed();
mode = Idle;
return ;
}
- // qDebug( "Debug: Retrieving file %s", file.name().latin1() );
+ // odebug << "Debug: Retrieving file " << file.name() << "" << oendl;
break;
case RetrieveGzipFile:
- qDebug("=-> starting tar process to receive .tgz file");
+ odebug << "=-> starting tar process to receive .tgz file" << oendl;
break;
case RetrieveBuffer:
// retrieve buffer mode
if ( !buf.open( IO_WriteOnly) ) {
emit failed();
mode = Idle;
return ;
}
- // qDebug( "Debug: Retrieving byte array" );
+ // odebug << "Debug: Retrieving byte array" << oendl;
break;
case Idle:
- qDebug("connection established but mode set to Idle; BUG!");
+ odebug << "connection established but mode set to Idle; BUG!" << oendl;
break;
}
}
void ServerDTP::connectionClosed()
{
- //qDebug( "Debug: Data connection closed %ld bytes written", bytes_written );
+ //odebug << "Debug: Data connection closed " << bytes_written << " bytes written" << oendl;
// send file mode
if ( SendFile == mode ) {
if ( bytes_written == file.size() )
emit completed();
else
emit failed();
}
// send buffer mode
else if ( SendBuffer == mode ) {
if ( bytes_written == buf.size() )
emit completed();
else
emit failed();
}
// retrieve file mode
else if ( RetrieveFile == mode ) {
file.close();
emit completed();
}
else if ( RetrieveGzipFile == mode ) {
- qDebug("Done writing ungzip file; closing input");
+ odebug << "Done writing ungzip file; closing input" << oendl;
gzipProc->flushStdin();
gzipProc->closeStdin();
}
// retrieve buffer mode
else if ( RetrieveBuffer == mode ) {
buf.close();
emit completed();
}
mode = Idle;
}
void ServerDTP::bytesWritten( int bytes )
{
bytes_written += bytes;
// send file mode
if ( SendFile == mode ) {
if ( bytes_written == file.size() ) {
- // qDebug( "Debug: Sending complete: %d bytes", file.size() );
+ // odebug << "Debug: Sending complete: " << file.size() << " bytes" << oendl;
file.close();
emit completed();
mode = Idle;
}
else if ( !file.atEnd() ) {
QCString s;
s.resize( block_size );
int bytes = file.readBlock( s.data(), block_size );
writeBlock( s.data(), bytes );
}
}
// send buffer mode
if ( SendBuffer == mode ) {
if ( bytes_written == buf.size() ) {
- // qDebug( "Debug: Sending complete: %d bytes", buf.size() );
+ // odebug << "Debug: Sending complete: " << buf.size() << " bytes" << oendl;
emit completed();
mode = Idle;
}
}
}
void ServerDTP::readyRead()
{
// retrieve file mode
if ( RetrieveFile == mode ) {
QCString s;
s.resize( bytesAvailable() );
readBlock( s.data(), bytesAvailable() );
file.writeBlock( s.data(), s.size() );
}
else if ( RetrieveGzipFile == mode ) {
if ( !gzipProc->isRunning() )
gzipProc->start(Opie::Core::OProcess::NotifyOnExit, (Opie::Core::OProcess::Communication) ( Opie::Core::OProcess::Stdin | Opie::Core::OProcess::Stdout ));
QByteArray s;
s.resize( bytesAvailable() );
readBlock( s.data(), bytesAvailable() );
gzipProc->writeStdin( s.data(), s.size() );
- qDebug("wrote %d bytes to ungzip ", s.size() );
+ odebug << "wrote " << s.size() << " bytes to ungzip " << oendl;
}
// retrieve buffer mode
else if ( RetrieveBuffer == mode ) {
QCString s;
s.resize( bytesAvailable() );
readBlock( s.data(), bytesAvailable() );
buf.writeBlock( s.data(), s.size() );
}
}
void ServerDTP::writeTargzBlock(Opie::Core::OProcess *, char *buffer, int buflen)
{
writeBlock( buffer, buflen );
- qDebug("writeTargzBlock %d", buflen);
+ odebug << "writeTargzBlock " << buflen << "" << oendl;
if ( !createTargzProc->isRunning() ) {
- qDebug("tar and gzip done");
+ odebug << "tar and gzip done" << oendl;
emit completed();
mode = Idle;
disconnect( gzipProc, SIGNAL( receivedStdout(Opie::Core::OProcess*,char*,int) ),
this, SLOT( writeTargzBlock(Opie::Core::OProcess*,char*,int) ) );
}
}
void ServerDTP::targzDone()
{
- //qDebug("targz done");
+ //odebug << "targz done" << oendl;
disconnect( createTargzProc, SIGNAL( receivedStdout(Opie::Core::OProcess*,char*,int) ),
this, SLOT( gzipTarBlock(Opie::Core::OProcess*,char*,int) ) );
gzipProc->closeStdin();
}
void ServerDTP::gzipTarBlock(Opie::Core::OProcess *, char *buffer, int buflen)
{
- //qDebug("gzipTarBlock");
+ //odebug << "gzipTarBlock" << oendl;
if ( !gzipProc->isRunning() ) {
- //qDebug("auto start gzip proc");
+ //odebug << "auto start gzip proc" << oendl;
gzipProc->start(Opie::Core::OProcess::NotifyOnExit, (Opie::Core::OProcess::Communication) ( Opie::Core::OProcess::Stdin | Opie::Core::OProcess::Stdout ));
}
gzipProc->writeStdin( buffer, buflen );
}
void ServerDTP::sendFile( const QString fn, const QHostAddress& host, Q_UINT16 port )
{
file.setName( fn );
mode = SendFile;
connectToHost( host.toString(), port );
}
@@ -1326,74 +1330,74 @@ void ServerDTP::sendGzipFile( const QString &fn,
connectToHost( host.toString(), port );
}
void ServerDTP::sendGzipFile( const QString &fn,
const QStringList &archiveTargets )
{
mode = SendGzipFile;
file.setName( fn );
QStringList args = "tar";
args += "-cv";
args += archiveTargets;
- qDebug("sendGzipFile %s", args.join(" ").latin1() );
+ odebug << "sendGzipFile " << args.join(" ") << "" << oendl;
createTargzProc->clearArguments( );
*createTargzProc << args;
connect( createTargzProc,
SIGNAL( receivedStdout(Opie::Core::OProcess*,char*,int) ), SLOT( gzipTarBlock(Opie::Core::OProcess*,char*,int) ) );
gzipProc->clearArguments( );
*gzipProc << "gzip";
connect( gzipProc, SIGNAL( receivedStdout(Opie::Core::OProcess*,char*,int) ),
SLOT( writeTargzBlock(Opie::Core::OProcess*,char*,int) ) );
}
void ServerDTP::gunzipDone()
{
- qDebug("gunzipDone");
+ odebug << "gunzipDone" << oendl;
disconnect( gzipProc, SIGNAL( processExited() ),
this, SLOT( gunzipDone() ) );
retrieveTargzProc->closeStdin();
disconnect( gzipProc, SIGNAL( receivedStdout(Opie::Core::OProcess*,char*,int) ),
this, SLOT( tarExtractBlock(Opie::Core::OProcess*,char*,int) ) );
}
void ServerDTP::tarExtractBlock(Opie::Core::OProcess *, char *buffer, int buflen)
{
- qDebug("tarExtractBlock");
+ odebug << "tarExtractBlock" << oendl;
if ( !retrieveTargzProc->isRunning() ) {
- qDebug("auto start ungzip proc");
+ odebug << "auto start ungzip proc" << oendl;
if ( !retrieveTargzProc->start(Opie::Core::OProcess::NotifyOnExit, Opie::Core::OProcess::Stdin) )
- qWarning(" failed to start tar -x process");
+ owarn << " failed to start tar -x process" << oendl;
}
retrieveTargzProc->writeStdin( buffer, buflen );
}
void ServerDTP::retrieveFile( const QString fn, const QHostAddress& host, Q_UINT16 port )
{
file.setName( fn );
mode = RetrieveFile;
connectToHost( host.toString(), port );
}
void ServerDTP::retrieveFile( const QString fn )
{
file.setName( fn );
mode = RetrieveFile;
}
void ServerDTP::retrieveGzipFile( const QString &fn )
{
- qDebug("retrieveGzipFile %s", fn.latin1());
+ odebug << "retrieveGzipFile " << fn << "" << oendl;
file.setName( fn );
mode = RetrieveGzipFile;
gzipProc->clearArguments();
*gzipProc << "gunzip";
connect( gzipProc, SIGNAL( readyReadStdout() ),
SLOT( tarExtractBlock() ) );
connect( gzipProc, SIGNAL( processExited() ),
SLOT( gunzipDone() ) );
}
void ServerDTP::retrieveGzipFile( const QString &fn, const QHostAddress& host, Q_UINT16 port )