Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F85203647
D317.1782680146.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D317.1782680146.diff
View Options
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -27,6 +27,11 @@
else()
set(KAZV_IS_WINDOWS 0)
endif()
+if(ANDROID)
+ set(KAZV_IS_ANDROID 1)
+else()
+ set(KAZV_IS_ANDROID 0)
+endif()
configure_file(kazv-version.cpp.in kazv-version.cpp)
configure_file(kazv-platform.hpp.in kazv-platform.hpp)
configure_file(kazv-defs.hpp.in kazv-defs.hpp)
diff --git a/src/kazv-platform.hpp.in b/src/kazv-platform.hpp.in
--- a/src/kazv-platform.hpp.in
+++ b/src/kazv-platform.hpp.in
@@ -9,3 +9,4 @@
#include <kazv-defs.hpp>
#define KAZV_IS_WINDOWS ${KAZV_IS_WINDOWS}
+#define KAZV_IS_ANDROID ${KAZV_IS_ANDROID}
diff --git a/src/kazv-session-lock-guard.cpp b/src/kazv-session-lock-guard.cpp
--- a/src/kazv-session-lock-guard.cpp
+++ b/src/kazv-session-lock-guard.cpp
@@ -7,7 +7,7 @@
#include <kazv-defs.hpp>
#include <kazv-platform.hpp>
#include <cstring>
-#if !KAZV_IS_WINDOWS
+#if !KAZV_IS_WINDOWS && !KAZV_IS_ANDROID
#include <fcntl.h>
#include <unistd.h>
#endif
@@ -21,7 +21,7 @@
void cleanup()
{
-#if !KAZV_IS_WINDOWS
+#if !KAZV_IS_WINDOWS && !KAZV_IS_ANDROID
qCDebug(kazvLog) << "KazvSessionLockGuard::Private::cleanup" << QString::fromStdString(lockFilePath);
if (fd != -1) {
qCDebug(kazvLog) << "unlocking session";
@@ -35,7 +35,7 @@
Private(const std::filesystem::path &sessionDir)
: lockFilePath((sessionDir / "lock").string())
{
-#if !KAZV_IS_WINDOWS
+#if !KAZV_IS_WINDOWS && !KAZV_IS_ANDROID
qCDebug(kazvLog) << "KazvSessionLockGuard::Private::Private" << QString::fromStdString(lockFilePath);
fd = open(lockFilePath.data(), O_RDWR | O_CREAT, S_IRUSR | S_IWUSR);
if (fd == -1) {
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Jun 28, 1:55 PM (22 h, 42 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1634389
Default Alt Text
D317.1782680146.diff (1 KB)
Attached To
Mode
D317: Disable session locking on Android
Attached
Detach File
Event Timeline
Log In to Comment