From 8abb8a82c94ee6a703097a116a4aea45e07b079e Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Thu, 18 Jul 2013 16:50:02 +0200 Subject: Fix rest of Linux bitrot --- ftnoir_protocol_wine/opentrack-wrapper-wine-windows.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'ftnoir_protocol_wine/opentrack-wrapper-wine-windows.cxx') 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); } -- cgit v1.2.3