summaryrefslogtreecommitdiffhomepage
path: root/compat/shm.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'compat/shm.cpp')
-rw-r--r--compat/shm.cpp17
1 files changed, 15 insertions, 2 deletions
diff --git a/compat/shm.cpp b/compat/shm.cpp
index 88a2811d..a933f7f9 100644
--- a/compat/shm.cpp
+++ b/compat/shm.cpp
@@ -7,10 +7,12 @@
#include "shm.h"
-#include <QDebug>
-
#if defined(_WIN32)
+#if !defined __WINE__
+# include <QDebug>
+#endif
+
#include <cstring>
#include <stdio.h>
@@ -114,7 +116,9 @@ PortableLockedShm::PortableLockedShm(const char* shmName, const char* mutexName,
if (!hMutex)
{
+#if !defined __WINE__
qDebug() << "CreateMutexA:" << (int) GetLastError();
+#endif
return;
}
@@ -128,7 +132,9 @@ PortableLockedShm::PortableLockedShm(const char* shmName, const char* mutexName,
if (!hMapFile)
{
+#if !defined __WINE__
qDebug() << "CreateFileMappingA:", (int) GetLastError();
+#endif
return;
}
@@ -140,7 +146,11 @@ PortableLockedShm::PortableLockedShm(const char* shmName, const char* mutexName,
mapSize);
if (!mem)
+ {
+#if !defined __WINE__
qDebug() << "MapViewOfFile:" << (int) GetLastError();
+#endif
+ }
}
PortableLockedShm::~PortableLockedShm()
@@ -157,7 +167,10 @@ PortableLockedShm::~PortableLockedShm()
return;
fail:
+ (void)0;
+#if !defined __WINE__
qDebug() << "failed to close mapping";
+#endif
}
bool PortableLockedShm::lock()