From:             
Operating system: OS X Lion
PHP version:      5.3.6
Package:          *Network Functions
Bug Type:         Bug
Bug description:After OS X Lion upgrade, file_get_contents issues a warning

Description:
------------
After I upgraded to Mac OS X Lion, my php script issues a warning for
file_get_contents(). If I run the script a second time, there's no
warnings.

This script runs when I open my browser to check if I'm logged into my
schools network. Then if I'm not logged in, it uses curl to log in. but the
problem is with file_get_contents().

I did test getaddrinfo() in a cpp program. When I used
"http://www.google.com"; it fails with the same error as php displays, but
when I use "www.google.com" it succeeds. This didn't happen before, but
could this be the problem? Then again the example on php.net is:
<?php
$homepage = file_get_contents('http://www.example.com/');
echo $homepage;
?>

Test script:
---------------
<?php

    $google = file_get_contents("http://www.google.com/";);

?>

Expected result:
----------------
No warnings, like when I had OS X Snow Leopard.

Actual result:
--------------
Warning: file_get_contents() [function.file-get-contents]:
php_network_getaddresses: getaddrinfo failed: nodename nor servname
provided, or not known in /Users/michael/Sites/personal/homepage.php on
line 3

Warning: file_get_contents(http://www.google.com/)
[function.file-get-contents]: failed to open stream:
php_network_getaddresses: getaddrinfo failed: nodename nor servname
provided, or not known in /Users/michael/Sites/personal/homepage.php on
line 3


-- 
Edit bug report at https://bugs.php.net/bug.php?id=55277&edit=1
-- 
Try a snapshot (PHP 5.4):            
https://bugs.php.net/fix.php?id=55277&r=trysnapshot54
Try a snapshot (PHP 5.3):            
https://bugs.php.net/fix.php?id=55277&r=trysnapshot53
Try a snapshot (trunk):              
https://bugs.php.net/fix.php?id=55277&r=trysnapshottrunk
Fixed in SVN:                        
https://bugs.php.net/fix.php?id=55277&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=55277&r=needdocs
Fixed in release:                    
https://bugs.php.net/fix.php?id=55277&r=alreadyfixed
Need backtrace:                      
https://bugs.php.net/fix.php?id=55277&r=needtrace
Need Reproduce Script:               
https://bugs.php.net/fix.php?id=55277&r=needscript
Try newer version:                   
https://bugs.php.net/fix.php?id=55277&r=oldversion
Not developer issue:                 
https://bugs.php.net/fix.php?id=55277&r=support
Expected behavior:                   
https://bugs.php.net/fix.php?id=55277&r=notwrong
Not enough info:                     
https://bugs.php.net/fix.php?id=55277&r=notenoughinfo
Submitted twice:                     
https://bugs.php.net/fix.php?id=55277&r=submittedtwice
register_globals:                    
https://bugs.php.net/fix.php?id=55277&r=globals
PHP 4 support discontinued:          
https://bugs.php.net/fix.php?id=55277&r=php4
Daylight Savings:                    https://bugs.php.net/fix.php?id=55277&r=dst
IIS Stability:                       
https://bugs.php.net/fix.php?id=55277&r=isapi
Install GNU Sed:                     
https://bugs.php.net/fix.php?id=55277&r=gnused
Floating point limitations:          
https://bugs.php.net/fix.php?id=55277&r=float
No Zend Extensions:                  
https://bugs.php.net/fix.php?id=55277&r=nozend
MySQL Configuration Error:           
https://bugs.php.net/fix.php?id=55277&r=mysqlcfg

Reply via email to