Req #53448 [NEW]: Syslog never returns false while a FALSE is documented in php manual
| From: | sskaje at gmail dot com | Date: | Thu, 02 Dec 2010 07:14:03 +0000 |
| Subject: | Req #53448 [NEW]: Syslog never returns false while a FALSE is documented in php manual | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-156677@lists.php.net to get a copy of this message | ||
From:
Operating system: Irrelevant
PHP version: Irrelevant
Package: Network related
Bug Type: Feature/Change Request
Bug description:Syslog never returns false while a FALSE is documented in php manual
Description:
------------
Sorry for the 'Package affected' select, network related is selected due to
the syslog() in php manual
in line 273 of ext/standard/syslog.c, i found following code:
[code]
272 php_syslog(priority, "%s", message);
273 RETURN_TRUE;
[/code]
while in http://cn.php.net/syslog, it writes:
[code]
Return Values
Returns TRUE on success or FALSE on failure.
[/code]
Another return value is null from :
[code]
267 if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ls",
&priority,
268 &message, &message_len) == FAILURE) {
269 return;
270 }
[/code]
null is returned only if there is a parameter error.
Can your bring a FALSE returned by php's syslog();
Test script:
---------------
null
Expected result:
----------------
null
Actual result:
--------------
null
--
Edit bug report at http://bugs.php.net/bug.php?id=53448&edit=1
--
Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=53448&r=trysnapshot52
Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=53448&r=trysnapshot53
Try a snapshot (trunk): http://bugs.php.net/fix.php?id=53448&r=trysnapshottrunk
Fixed in SVN: http://bugs.php.net/fix.php?id=53448&r=fixed
Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=53448&r=needdocs
Fixed in release: http://bugs.php.net/fix.php?id=53448&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=53448&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=53448&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=53448&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=53448&r=support
Expected behavior: http://bugs.php.net/fix.php?id=53448&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=53448&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=53448&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=53448&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=53448&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=53448&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=53448&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=53448&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=53448&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=53448&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=53448&r=mysqlcfg