On 11/14/2006 08:26 AM, Andi Gutmans wrote:
Sounds like something which indeed isn't worth breaking. Was this
intentional?

Sara says it was intentional, that's why I decided to write to the list.
I don't think such intentional breaks should take place in any PHP version.

-----Original Message-----
From: Antony Dovgal [mailto:[EMAIL PROTECTED] Sent: Monday, November 13, 2006 1:39 PM
To: php-dev
Subject: [PHP-DEV] fgets()/fgetss() BC break in HEAD

Hello all.

I'd like to continue recent IRC discussion here, to draw more attention to this issue.

At the moment functions fgets() and fgetss() are broken in HEAD, as they return <maxlen> characters instead of <maxlen - 1>, as they do in 5.2 (and I'm pretty sure this is the way they used to work since their very first appearance in PHP). So, anybody relying on fgets($fp, 10) to return 9 characters would get 10 characters instead.

Yes, this behaviour is not very intuitive for those who are not familiar with fgets() in C, but it's well documented and pretty much expected.

I believe this is an unreasonable BC break and I strongly believe it should be fixed. There are 0 reasons to do it (without any discussion) and it can only result in more users' confusion, even if the original purpose was the contrary.

--
Wbr,
Antony Dovgal

--
PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php




--
Wbr, Antony Dovgal

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to