#23812 [Opn->Asn]: Error (warning) in Net_DNS v. 1.00b1
| From: | arnaud@php.net | Date: | Mon, 26 May 2003 14:31:16 +0000 |
| Subject: | #23812 [Opn->Asn]: Error (warning) in Net_DNS v. 1.00b1 | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-16716@lists.php.net to get a copy of this message | ||
ID: 23812
Updated by: arnaud@php.net
Reported By: colin at easydns dot com
-Status: Open
+Status: Assigned
Bug Type: PEAR related
Operating System: Linux
PHP Version: 4.3.1
-Assigned To:
+Assigned To: pollita
Previous Comments:
------------------------------------------------------------------------
[2003-05-26 09:24:09] colin at easydns dot com
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 this bug report at http://bugs.php.net/?id=23812&edit=1