Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation fails on Visual Studio 2017 (VS 15.0) #112

Open
madscientist opened this issue Jan 23, 2018 · 1 comment
Open

Compilation fails on Visual Studio 2017 (VS 15.0) #112

madscientist opened this issue Jan 23, 2018 · 1 comment

Comments

@madscientist
Copy link

This patch is needed for (at least) Visual Studio 2017. Not sure about earlier versions.

--- a/bindings/java/src/jni/win32/eventlog.c	2010-04-28 17:00:00.000000000 -0400
+++ b/bindings/java/src/jni/win32/eventlog.c	2018-01-23 15:55:39.605908161 -0500
@@ -130,7 +130,8 @@
         }
     }
 
-    ptr = wcstok(msgdll, FILESEP);
+    LPWSTR ex;
+    ptr = wcstok(msgdll, FILESEP, &ex);
     while (ptr) {
         HINSTANCE hlib;
 
@@ -150,7 +151,7 @@
                 break;
             }
         }
-        ptr = wcstok(NULL, FILESEP);
+        ptr = wcstok(NULL, FILESEP, &ex);
     }
 
     if (msgbuf) {
@zw3413
Copy link

zw3413 commented Feb 22, 2018

I used the _wcstok(msgdll,FILESEP) instead of wcstok(msgdll,FILESEP,&ex), vs2015.
Will be happy to talk if you have other founds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants