OSDN Git Service

drkonqi: adjust to KDebug changes
authorIvailo Monev <xakepa10@gmail.com>
Sun, 8 Aug 2021 19:01:11 +0000 (22:01 +0300)
committerIvailo Monev <xakepa10@gmail.com>
Sun, 8 Aug 2021 19:01:11 +0000 (22:01 +0300)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
drkonqi/detachedprocessmonitor.cpp
drkonqi/systeminformation.cpp

index 8088ed2..601eeff 100644 (file)
@@ -17,6 +17,8 @@
 #include "detachedprocessmonitor.h"
 
 #include <signal.h>
+#include <string.h>
+#include <errno.h>
 
 #include <QtCore/qcoreevent.h>
 
@@ -37,7 +39,7 @@ void DetachedProcessMonitor::timerEvent(QTimerEvent *event)
 {
     Q_ASSERT(m_pid != 0);
     if (::kill(m_pid, 0) < 0) {
-        kDebug() << "Process" << m_pid << "finished. kill(2) returned errno:" << perror;
+        kDebug() << "Process" << m_pid << "finished. kill(2) returned errno:" << ::strerror(errno);
         killTimer(event->timerId());
         m_pid = 0;
         emit processFinished();
index c0c0cfb..3483ff7 100644 (file)
@@ -24,6 +24,8 @@
 
 #ifdef HAVE_UNAME
 # include <sys/utsname.h>
+# include <string.h>
+# include <errno.h>
 #endif
 
 #include <QtCore/QFile>
@@ -49,7 +51,7 @@ QString SystemInformation::fetchOSDetailInformation() const
 #ifdef HAVE_UNAME
     struct utsname buf;
     if (::uname(&buf) == -1) {
-        kDebug() << "call to uname failed" << perror;
+        kDebug() << "call to uname failed" << ::strerror(errno);
     } else {
         operatingSystem = QString::fromLocal8Bit(buf.sysname) + ' '
             + QString::fromLocal8Bit(buf.release) + ' '