summaryrefslogtreecommitdiff
path: root/ext/mysqli/mysqli_nonapi.c
diff options
context:
space:
mode:
authorAndrey Hristov <andrey@php.net>2008-10-27 14:34:35 +0000
committerAndrey Hristov <andrey@php.net>2008-10-27 14:34:35 +0000
commit34ca27a1914437e6b092912f205d7b5d2fecd4f7 (patch)
tree8f5fd88ffd152eec04728e5aeb4b8e3678e01738 /ext/mysqli/mysqli_nonapi.c
parent5668f32b68bfb2d6f26e10b01f10a153c480d3e6 (diff)
downloadphp-git-34ca27a1914437e6b092912f205d7b5d2fecd4f7.tar.gz
MFH: Fix an issue with mysqli.default_port not being used
Diffstat (limited to 'ext/mysqli/mysqli_nonapi.c')
-rw-r--r--ext/mysqli/mysqli_nonapi.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c
index 953ccda865..2209960fb2 100644
--- a/ext/mysqli/mysqli_nonapi.c
+++ b/ext/mysqli/mysqli_nonapi.c
@@ -127,7 +127,9 @@ void mysqli_common_connect(INTERNAL_FUNCTION_PARAMETERS, zend_bool is_real_conne
if (!socket_len || !socket) {
socket = MyG(default_socket);
}
-
+ if (!port){
+ port = MyG(default_port);
+ }
if (!passwd) {
passwd = MyG(default_pw);
passwd_len = strlen(SAFE_STR(passwd));