#23812 [NEW]: Error (warning) in Net_DNS v. 1.00b1
| From: | colin at easydns dot com | Date: | Mon, 26 May 2003 14:24:09 +0000 |
| Subject: | #23812 [NEW]: Error (warning) in Net_DNS v. 1.00b1 | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-16715@lists.php.net to get a copy of this message | ||
From: colin at easydns dot com
Operating system: Linux
PHP version: 4.3.1
PHP Bug Type: PEAR related
Bug description: Error (warning) in Net_DNS v. 1.00b1
My logs started showing this:
PHP Warning: unpack() [http://www.php.net/function.unpack]: Type n: not
enough input, need 2, have 0 in /usr/local/lib/php/Net/DNS/Resolver.php on
line 745
I think this diff will fix things:
--- Resolver.php.orig 2003-05-26 10:18:52.000000000 -0400
+++ Resolver.php 2003-05-26 10:12:14.000000000 -0400
@@ -742,7 +742,7 @@
socket_set_timeout($sock, $timeout);
$buf = fread($sock, 2);
$e = socket_get_status($sock);
- $len = unpack('nint', $buf);
+ $len = unpack('n2int', $buf);
$len = $len['int'];
if (!$len) {
continue;
- Colin
--
Edit bug report at http://bugs.php.net/?id=23812&edit=1
--
Try a CVS snapshot: http://bugs.php.net/fix.php?id=23812&r=trysnapshot
Fixed in CVS: http://bugs.php.net/fix.php?id=23812&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=23812&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=23812&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=23812&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=23812&r=support
Expected behavior: http://bugs.php.net/fix.php?id=23812&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=23812&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=23812&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=23812&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=23812&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=23812&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=23812&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=23812&r=gnused