From: <ks...@us...> - 2010-03-26 16:13:29
|
Revision: 2081 http://nghost.svn.sourceforge.net/nghost/?rev=2081&view=rev Author: kshots Date: 2010-03-26 16:13:20 +0000 (Fri, 26 Mar 2010) Log Message: ----------- * Found a few session bus entries in nscan - moved to system bus Modified Paths: -------------- nghost2/branches/nghost2-qt/src/nscan/nscan.cpp Modified: nghost2/branches/nghost2-qt/src/nscan/nscan.cpp =================================================================== --- nghost2/branches/nghost2-qt/src/nscan/nscan.cpp 2010-03-24 02:29:01 UTC (rev 2080) +++ nghost2/branches/nghost2-qt/src/nscan/nscan.cpp 2010-03-26 16:13:20 UTC (rev 2081) @@ -13,7 +13,7 @@ nscan::nscan() : QObject(NULL), m_watch(new QSocketNotifier(inotify_init(), QSocketNotifier::Read, this)), m_sm(new QSignalMapper(this)), m_path(QDBusObjectPath("/org/openice/nscan")) { - QDBusConnection::connectToBus(QDBusConnection::SessionBus, "nscanSession"); + QDBusConnection::connectToBus(QDBusConnection::SystemBus, "nscanSession"); QDBusAbstractAdaptor * dbus = new NscanAdaptor(this); connect(this, SIGNAL(SimultaneousScansChanged(int, const QList<QDBusObjectPath> &)), dbus, SIGNAL(SimultaniousScansChanged(int, const QList<QDBusObjectPath> &))); connect(this, SIGNAL(SourceAdded(const QString &, const QString &)), dbus, SIGNAL(SourceAdded(const QString &, const QString &))); @@ -21,13 +21,13 @@ connect(this, SIGNAL(watchTriggered(int, int, QString, QString)), dbus, SIGNAL(watchTriggered(int, int, QString, QString))); if(!QDBusConnection::systemBus().registerObject("/org/openice/nscan", this)) { - QDBusError e = QDBusConnection::sessionBus().lastError(); + QDBusError e = QDBusConnection::systemBus().lastError(); ndebug::out(ndebug::LOG_ERR, "%s:%s(%d) - Failed to register dbus object '/org/openice/nscan' - %s: %s", __FILE__, __FUNCTION__, __LINE__, e.name().toAscii().constData(), e.message().toAscii().constData()); exit(1); } if(!QDBusConnection::systemBus().registerService("org.openice.nscan")) { - QDBusError e = QDBusConnection::sessionBus().lastError(); + QDBusError e = QDBusConnection::systemBus().lastError(); ndebug::out(ndebug::LOG_ERR, "%s:%s(%d) - Failed to register dbus service 'org.openice.nscan' - %s: %s", __FILE__, __FUNCTION__, __LINE__, e.name().toAscii().constData(), e.message().toAscii().constData()); } @@ -49,6 +49,7 @@ QDBusObjectPath nscan::CreateScan(const QString & tableName, const QStringList & paths, const QStringList & fileextensions, const QString & daoclass) { + ndebug::out(ndebug::LOG_DEBUG, "Got a 'CreateScan' request on table '%s' and daoclass '%s'", tableName.toAscii().constData(), daoclass.toAscii().constData()); foreach(QString s, paths) { const int wd = inotify_add_watch(m_watch->socket(), s.toAscii().constData(), IN_CLOSE_WRITE | IN_CREATE | IN_DELETE | IN_MOVE); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |