#43502 [Opn->Fbk]: Tiny patches for using dns_get_mx()

From: Date: Wed, 05 Dec 2007 10:08:35 +0000
Subject: #43502 [Opn->Fbk]: Tiny patches for using dns_get_mx()
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-120379@lists.php.net to get a copy of this message
ID: 43502 Updated by: jani@php.net Reported By: tsumai at kagoya dot com -Status: Open +Status: Feedback Bug Type: Network related Operating System: Vine Linux 4.1 PHP Version: 5.2.5 New Comment: That include is already there, why do you think you need it to be included twice? How exactly did you build PHP? Previous Comments: ------------------------------------------------------------------------ [2007-12-05 09:23:44] tsumai at kagoya dot com Description: ------------ The following message is generated when a PHP file is viewed: (it is run by libphp5.so module for Apache 1.3.37) Fatal error: Call to undefined function getmxrr() in /home/testuser/public_html/test.php on line 2 The content of the file test.php is as follows: <? getmxrr('example.com', $a); echo $a[0]; ?> The following patch works well in my environment: diff -urN php-5.2.5.orig/ext/standard/basic_functions.c php-5.2.5/ext/standard/basic_functions.c --- php-5.2.5.orig/ext/standard/basic_functions.c 2007-10-22 16:37:20.000000000 +0900 +++ php-5.2.5/ext/standard/basic_functions.c 2007-12-05 17:39:35.000000000 +0900 @@ -20,6 +20,11 @@ /* $Id: basic_functions.c,v 1.725.2.31.2.66 2007/10/22 07:37:20 dmitry Exp $ */ #include "php.h" +#ifdef PHP_WIN32 +#include "config.w32.h" +#else +#include <php_config.h> +#endif #include "php_streams.h" #include "php_main.h" #include "php_globals.h" diff -urN php-5.2.5.orig/ext/standard/dns.c php-5.2.5/ext/standard/dns.c --- php-5.2.5.orig/ext/standard/dns.c 2007-06-26 20:04:55.000000000 +0900 +++ php-5.2.5/ext/standard/dns.c 2007-12-05 17:33:10.000000000 +0900 @@ -22,6 +22,11 @@ /* {{{ includes */ #include "php.h" +#ifdef PHP_WIN32 +#include "config.w32.h" +#else +#include <php_config.h> +#endif #if HAVE_SYS_SOCKET_H #include <sys/socket.h> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=43502&edit=1

« previous php.bugs (#120379) next »