summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_protocol_wine
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2013-07-18 16:50:02 +0200
committerStanislaw Halik <sthalik@misaki.pl>2013-07-18 16:50:02 +0200
commit8abb8a82c94ee6a703097a116a4aea45e07b079e (patch)
tree0ac806cb265fa4027ed77e565f92ec7e15ce6a94 /ftnoir_protocol_wine
parent3c3ac0056e0751c255008d6fdeecd9b331663ffc (diff)
Fix rest of Linux bitrot
Diffstat (limited to 'ftnoir_protocol_wine')
-rw-r--r--ftnoir_protocol_wine/ftnoir_protocol_wine.cpp6
-rw-r--r--ftnoir_protocol_wine/ftnoir_protocol_wine.h2
-rw-r--r--ftnoir_protocol_wine/opentrack-wrapper-wine-windows.cxx3
3 files changed, 3 insertions, 8 deletions
diff --git a/ftnoir_protocol_wine/ftnoir_protocol_wine.cpp b/ftnoir_protocol_wine/ftnoir_protocol_wine.cpp
index 82dfb7b9..c6c038d9 100644
--- a/ftnoir_protocol_wine/ftnoir_protocol_wine.cpp
+++ b/ftnoir_protocol_wine/ftnoir_protocol_wine.cpp
@@ -47,6 +47,7 @@ FTNoIR_Protocol::FTNoIR_Protocol() : lck_shm(WINE_SHM_NAME, WINE_MTX_NAME, sizeo
shm = (WineSHM*) lck_shm.mem;
memset(shm, 0, sizeof(*shm));
}
+ wrapper.start("wine", QStringList() << (QCoreApplication::applicationDirPath() + "/opentrack-wrapper-wine.exe.so"));
}
/** destructor **/
@@ -60,11 +61,6 @@ FTNoIR_Protocol::~FTNoIR_Protocol()
shm_unlink("/" WINE_SHM_NAME);
}
-void FTNoIR_Protocol::Initialize()
-{
- wrapper.start("wine", QStringList() << (QCoreApplication::applicationDirPath() + "/opentrack-wrapper-wine.exe.so"));
-}
-
void FTNoIR_Protocol::sendHeadposeToGame( double *headpose, double *rawheadpose ) {
if (shm)
{
diff --git a/ftnoir_protocol_wine/ftnoir_protocol_wine.h b/ftnoir_protocol_wine/ftnoir_protocol_wine.h
index 7c07323d..c4837992 100644
--- a/ftnoir_protocol_wine/ftnoir_protocol_wine.h
+++ b/ftnoir_protocol_wine/ftnoir_protocol_wine.h
@@ -50,8 +50,6 @@ public:
FTNoIR_Protocol();
~FTNoIR_Protocol();
- void Initialize();
-
bool checkServerInstallationOK();
void sendHeadposeToGame(double* headpose, double* rawheadpose );
diff --git a/ftnoir_protocol_wine/opentrack-wrapper-wine-windows.cxx b/ftnoir_protocol_wine/opentrack-wrapper-wine-windows.cxx
index 86ba4a41..6d5484a9 100644
--- a/ftnoir_protocol_wine/opentrack-wrapper-wine-windows.cxx
+++ b/ftnoir_protocol_wine/opentrack-wrapper-wine-windows.cxx
@@ -10,7 +10,7 @@
void create_registry_key(void) {
char dir[8192];
- if (GetCurrentDirectoryA(8192, dir) < 8192)
+ if (GetCurrentDirectoryA(8192, dir) < 8190)
{
HKEY hkpath;
if (RegCreateKeyExA(HKEY_CURRENT_USER,
@@ -26,6 +26,7 @@ void create_registry_key(void) {
for (int i = 0; dir[i]; i++)
if (dir[i] == '\\')
dir[i] = '/';
+ strcat(dir, "/");
(void) RegSetValueExA(hkpath, "Path", 0, REG_SZ, (BYTE*) dir, strlen(dir) + 1);
RegCloseKey(hkpath);
}