как ни странно, у меня
Код:
$ php -r '$fd=fopen("test","r"); $buff = fgets($fd, 2); var_dump(ord($buff) == 10);'
bool(true)
а вот в ZendStudio false
-~{}~ 08.11.07 15:42:
PHP 5.2.4 with Suhosin-Patch 0.9.6.2 (cli) (built: Sep 14 2007 10:11:01)
Copyright (c) 1997-2007 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies
with Zend Extension Manager v1.2.0, Copyright (c) 2003-2007, by Zend Technologies
with Suhosin v0.9.20, Copyright (c) 2002-2006, by Hardened-PHP Project
with Zend Optimizer v3.2.4, Copyright (c) 1998-2007, by Zend Technologies
with Zend Debugger v5.2.5, Copyright (c) 1999-2007, by Zend Technologies