summaryrefslogtreecommitdiff
path: root/ext/mysqlnd/mysqlnd_net.c
diff options
context:
space:
mode:
authorAndrey Hristov <andrey@php.net>2011-03-18 14:56:20 +0000
committerAndrey Hristov <andrey@php.net>2011-03-18 14:56:20 +0000
commitf06443593eb832dd1c796c787f079f9aeb3fe691 (patch)
tree82099e891e7d610625e3435a72cf15be15e09fa3 /ext/mysqlnd/mysqlnd_net.c
parentc90df5850b6540e5b14e7db81bbe64880b5c98a6 (diff)
downloadphp-git-f06443593eb832dd1c796c787f079f9aeb3fe691.tar.gz
add a proxy for sppintf and vspprintf
Diffstat (limited to 'ext/mysqlnd/mysqlnd_net.c')
-rw-r--r--ext/mysqlnd/mysqlnd_net.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c
index 29bb2de8e3..26085fe610 100644
--- a/ext/mysqlnd/mysqlnd_net.c
+++ b/ext/mysqlnd/mysqlnd_net.c
@@ -124,7 +124,7 @@ MYSQLND_METHOD(mysqlnd_net, connect)(MYSQLND_NET * net, const char * const schem
net->stream = php_stream_open_wrapper((char*) scheme + sizeof("pipe://") - 1, "r+", streams_options, NULL);
} else {
if (persistent) {
- hashed_details_len = spprintf(&hashed_details, 0, "%p", net);
+ hashed_details_len = mnd_sprintf(&hashed_details, 0, "%p", net);
DBG_INF_FMT("hashed_details=%s", hashed_details);
}
@@ -140,7 +140,7 @@ MYSQLND_METHOD(mysqlnd_net, connect)(MYSQLND_NET * net, const char * const schem
}
if (*errstr || !net->stream) {
if (hashed_details) {
- efree(hashed_details); /* allocated by spprintf */
+ mnd_sprintf_free(hashed_details);
}
*errcode = CR_CONNECTION_ERROR;
DBG_RETURN(FAIL);
@@ -168,7 +168,7 @@ MYSQLND_METHOD(mysqlnd_net, connect)(MYSQLND_NET * net, const char * const schem
/* Shut-up the streams, they don't know what they are doing */
net->stream->__exposed = 1;
#endif
- efree(hashed_details);
+ mnd_sprintf_free(hashed_details);
}
/*
Streams are not meant for C extensions! Thus we need a hack. Every connected stream will