summaryrefslogtreecommitdiff
path: root/bindings/java
diff options
context:
space:
mode:
Diffstat (limited to 'bindings/java')
-rw-r--r--bindings/java/Context.cpp12
-rw-r--r--bindings/java/Socket.cpp11
2 files changed, 5 insertions, 18 deletions
diff --git a/bindings/java/Context.cpp b/bindings/java/Context.cpp
index d2138c3..652a120 100644
--- a/bindings/java/Context.cpp
+++ b/bindings/java/Context.cpp
@@ -22,7 +22,8 @@
#include <assert.h>
#include <errno.h>
-#include "zmq.h"
+#include "../c/zmq.h"
+
#include "org_zmq_Context.h"
static jfieldID ctx_handle_fid = NULL;
@@ -34,14 +35,7 @@ static void raise_exception (JNIEnv *env, int err)
assert (exception_class);
// Get text description of the exception.
-#if defined _MSC_VER
-#pragma warning (push)
-#pragma warning (disable:4996)
-#endif
- const char *err_msg = strerror (err);
-#if defined _MSC_VER
-#pragma warning (pop)
-#endif
+ const char *err_msg = zmq_strerror (err);
// Raise the exception.
int rc = env->ThrowNew (exception_class, err_msg);
diff --git a/bindings/java/Socket.cpp b/bindings/java/Socket.cpp
index cf6b1de..26c6003 100644
--- a/bindings/java/Socket.cpp
+++ b/bindings/java/Socket.cpp
@@ -23,8 +23,8 @@
#include <errno.h>
#include "../../src/stdint.hpp"
+#include "../c/zmq.h"
-#include "zmq.h"
#include "org_zmq_Socket.h"
static jfieldID socket_handle_fid = NULL;
@@ -37,14 +37,7 @@ static void raise_exception (JNIEnv *env, int err)
assert (exception_class);
// Get text description of the exception.
-#if defined _MSC_VER
-#pragma warning (push)
-#pragma warning (disable:4996)
-#endif
- const char *err_msg = strerror (err);
-#if defined _MSC_VER
-#pragma warning (pop)
-#endif
+ const char *err_msg = zmq_strerror (err);
// Raise the exception.
int rc = env->ThrowNew (exception_class, err_msg);