Skip to content

Commit 921d8ca

Browse files
author
Ilia Alshanetsky
committed
Fixed bug #50023 (pdo_mysql doesn't use PHP_MYSQL_UNIX_SOCK_ADDR)
# Original patch by six at aegis-corp dot org
1 parent 4387237 commit 921d8ca

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

ext/pdo_mysql/pdo_mysql.c

+5-2
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,14 @@ ZEND_DECLARE_MODULE_GLOBALS(pdo_mysql);
4040

4141
#ifndef PHP_WIN32
4242
# ifndef PDO_MYSQL_UNIX_ADDR
43-
# define PDO_MYSQL_UNIX_ADDR "/tmp/mysql.sock"
43+
# ifdef PHP_MYSQL_UNIX_SOCK_ADDR
44+
# define PDO_MYSQL_UNIX_ADDR PHP_MYSQL_UNIX_SOCK_ADDR
45+
# else
46+
# define PDO_MYSQL_UNIX_ADDR "/tmp/mysql.sock"
47+
# endif
4448
# endif
4549
#endif
4650

47-
4851
/* {{{ PHP_INI_BEGIN
4952
*/
5053
PHP_INI_BEGIN()

0 commit comments

Comments
 (0)