summaryrefslogtreecommitdiff
path: root/library/global.cpp
Side-by-side diff
Diffstat (limited to 'library/global.cpp') (more/less context) (show whitespace changes)
-rw-r--r--library/global.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/library/global.cpp b/library/global.cpp
index 7bdd0b1..1895006 100644
--- a/library/global.cpp
+++ b/library/global.cpp
@@ -537,13 +537,15 @@ void Global::invoke(const QString &c)
#if !defined(QT_NO_COP)
QString ap=list[0];
// see if the application is already running
// XXX should lock file /tmp/qcop-msg-ap
if ( QCopChannel::isRegistered( ("QPE/Application/" + ap).latin1() ) ) {
// If the channel is already register, the app is already running, so show it.
- { QCopEnvelope env( ("QPE/Application/" + ap).latin1(), "raise()" ); }
+ {
+ QCopEnvelope env( ("QPE/Application/" + ap).latin1(), "raise()" );
+ }
//QCopEnvelope e("QPE/System", "notBusy(QString)" );
//e << ap;
return;
}
// XXX should unlock file /tmp/qcop-msg-ap
@@ -570,12 +572,13 @@ void Global::invoke(const QString &c)
for ( j = 0; j < list.count(); j++ )
slist.append( list[j].utf8() );
const char **args = new const char *[slist.count() + 1];
for ( j = 0; j < slist.count(); j++ )
args[j] = slist.at(j);
+
args[j] = NULL;
#if !defined(QT_NO_COP)
// an attempt to show a wait...
// more logic should be used, but this will be fine for the moment...
QCopEnvelope ( "QPE/System", "busy()" );
@@ -644,12 +647,13 @@ void Global::invoke(const QString &c)
}
if ( success )
StartingAppList::add( list[0] );
else
QMessageBox::warning( 0, "Error", "Could not start the application " + c, "Ok", 0, 0, 0, 1 );
}
+ delete [] args;
#endif //QT_NO_QWS_MULTIPROCESS
}
/*!
Executes the application identfied by \a c, passing \a