Permalink
Browse files

Minor tweak to binding

  • Loading branch information...
1 parent 5f5224c commit 1aae01fbf131eea5f2d08e9ec7bdf90e17c28e6d @mscdex committed Nov 16, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/binding.cc
View
@@ -297,7 +297,7 @@ class Client : public ObjectWrap {
config.port,
NULL,
config.client_opts);
- if (!mysql_ret)
+ if (!mysql_ret && mysql_errno(&mysql) > 0)
return emit_error(err_symbol, true);
mysql_sock = mysql_get_socket(&mysql);
poll_handle = (uv_poll_t*) malloc(sizeof(uv_poll_t));

0 comments on commit 1aae01f

Please sign in to comment.