diff options
author | Dmitry Stogov <dmitry@zend.com> | 2014-08-13 14:51:48 +0400 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2014-08-13 14:51:48 +0400 |
commit | 5a06ac88da693623fb471494a3759f04582f966e (patch) | |
tree | 110dfad2a5c8462d4b354c99f369c2e62dc95d12 /ext/mysqlnd/mysqlnd_net.c | |
parent | b8517e410ce4209d05f911d35d9ec77a2cc191c9 (diff) | |
download | php-git-5a06ac88da693623fb471494a3759f04582f966e.tar.gz |
cleanup (use zend_string* instead of char*)
Diffstat (limited to 'ext/mysqlnd/mysqlnd_net.c')
-rw-r--r-- | ext/mysqlnd/mysqlnd_net.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c index 76e49a5d9d..84757f88c1 100644 --- a/ext/mysqlnd/mysqlnd_net.c +++ b/ext/mysqlnd/mysqlnd_net.c @@ -160,7 +160,7 @@ MYSQLND_METHOD(mysqlnd_net, open_tcp_or_unix)(MYSQLND_NET * const net, const cha unsigned int streams_flags = STREAM_XPORT_CLIENT | STREAM_XPORT_CONNECT; char * hashed_details = NULL; int hashed_details_len = 0; - char * errstr = NULL; + zend_string *errstr = NULL; int errcode = 0; struct timeval tv; dtor_func_t origin_dtor; @@ -190,10 +190,10 @@ MYSQLND_METHOD(mysqlnd_net, open_tcp_or_unix)(MYSQLND_NET * const net, const cha mnd_sprintf_free(hashed_details); } errcode = CR_CONNECTION_ERROR; - SET_CLIENT_ERROR(*error_info, errcode? errcode:CR_CONNECTION_ERROR, UNKNOWN_SQLSTATE, errstr); + SET_CLIENT_ERROR(*error_info, errcode? errcode:CR_CONNECTION_ERROR, UNKNOWN_SQLSTATE, errstr->val); if (errstr) { /* no mnd_ since we don't allocate it */ - efree(errstr); + STR_RELEASE(errstr); } DBG_RETURN(NULL); } |