Bug #66594 [NEW]: Please use -Wformat=security when compiling and testing releases
| From: | ondrej@php.net | Date: | Tue, 28 Jan 2014 11:21:08 +0000 |
| Subject: | Bug #66594 [NEW]: Please use -Wformat=security when compiling and testing releases | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-184051@lists.php.net to get a copy of this message | ||
From: ondrej
Operating system: Any
PHP version: 5.6.0alpha1
Package: phpdbg
Bug Type: Bug
Bug description:Please use -Wformat=security when compiling and testing releases
Description:
------------
/tmp/buildd/php5-5.6.0~alpha1+dfsg/sapi/phpdbg/phpdbg_cmd.c:482:5:
error: format not a string literal and no format arguments
[-Werror=format-security]
A very short patch:
--- php5.orig/sapi/phpdbg/phpdbg_cmd.c
+++ php5/sapi/phpdbg/phpdbg_cmd.c
@@ -479,7 +479,7 @@ disconnect:
#ifndef HAVE_LIBREADLINE
if (!(PHPDBG_G(flags) & PHPDBG_IS_REMOTE)) {
- if (!phpdbg_write(phpdbg_get_prompt(TSRMLS_C))) {
+ if (!phpdbg_write("%s", phpdbg_get_prompt(TSRMLS_C))) {
goto disconnect;
}
}
--
Edit bug report at https://bugs.php.net/bug.php?id=66594&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=66594&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=66594&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=66594&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=66594&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=66594&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=66594&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=66594&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=66594&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=66594&r=support
Expected behavior: https://bugs.php.net/fix.php?id=66594&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=66594&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=66594&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=66594&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=66594&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=66594&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=66594&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=66594&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=66594&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=66594&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=66594&r=mysqlcfg