summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/sub.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sub.cpp b/src/sub.cpp
index bd70a55..d2b4f96 100644
--- a/src/sub.cpp
+++ b/src/sub.cpp
@@ -50,7 +50,7 @@ int zmq::sub_t::xsetsockopt (int option_, const void *optval_,
memcpy (data + 1, optval_, optvallen_);
// Pass it further on in the stack.
- int err;
+ int err = 0;
int rc = xsend (&msg, 0);
if (rc != 0)
err = errno;