mirror of
https://github.com/php/php-src.git
synced 2026-04-25 08:58:28 +02:00
Make it possible to specify both a port and a socket in mysql_[p]connect
@ Make it possible to specify both a port and a socket in mysql_[p]connect
This commit is contained in:
@@ -400,6 +400,11 @@ static void php_mysql_do_connect(INTERNAL_FUNCTION_PARAMETERS,int persistent)
|
||||
tmp++;
|
||||
if (tmp[0] != '/') {
|
||||
port = atoi(tmp);
|
||||
if(tmp=strchr(tmp,':')) {
|
||||
*tmp=0;
|
||||
tmp++;
|
||||
socket=tmp;
|
||||
}
|
||||
} else {
|
||||
socket = tmp;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user