Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 3.7.2

Bug #14520 Notice: Undefined offset: 1 in /usr/share/php/PHP/CodeSniffer/File.php on line
Submitted: 2008-08-18 15:23 UTC
From: str Assigned: squiz
Status: Closed Package: PHP_CodeSniffer (version 1.1.0)
PHP Version: 5.2.4 OS: GNU/Linux Debian
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 47 - 6 = ?

 
 [2008-08-18 15:23 UTC] str (Stuardo Rodríguez)
Description: ------------ Running the phpcs from phpUnderControl, with this params --report=checkstyle, I get the following errors Test script: --------------- Notice: Undefined offset: 1 in /usr/share/php/PHP/CodeSniffer/File.php on line 510 Call Stack: 0.0013 60756 1. {main}() /usr/bin/phpcs:0 0.0244 1080940 2. PHP_CodeSniffer_CLI->process() /usr/bin/phpcs:30 0.0250 1081732 3. PHP_CodeSniffer->process() /usr/share/php/PHP/CodeSniffer/CLI.php:334 0.0990 2524540 4. PHP_CodeSniffer->processFiles() /usr/share/php/PHP/CodeSniffer.php:289 22.2126 12483252 5. PHP_CodeSniffer->processFile() /usr/share/php/PHP/CodeSniffer.php:566 22.2179 12557940 6. PHP_CodeSniffer_File->start() /usr/share/php/PHP/CodeSniffer.php:624 22.2183 12560080 7. PEAR_Sniffs_Commenting_FileCommentSniff->process() /usr/share/php/PHP/CodeSniffer/File.php:380 22.2184 12560732 8. PHP_CodeSniffer_File->addError() /usr/share/php/PHP/CodeSniffer/Standards/PEAR/Sniffs/Commenting/FileCommentSniff.php:177 Notice: Undefined offset: 1 in /usr/share/php/PHP/CodeSniffer/File.php on line 511 Call Stack: 0.0013 60756 1. {main}() /usr/bin/phpcs:0 0.0244 1080940 2. PHP_CodeSniffer_CLI->process() /usr/bin/phpcs:30 0.0250 1081732 3. PHP_CodeSniffer->process() /usr/share/php/PHP/CodeSniffer/CLI.php:334 0.0990 2524540 4. PHP_CodeSniffer->processFiles() /usr/share/php/PHP/CodeSniffer.php:289 22.2126 12483252 5. PHP_CodeSniffer->processFile() /usr/share/php/PHP/CodeSniffer.php:566 22.2179 12557940 6. PHP_CodeSniffer_File->start() /usr/share/php/PHP/CodeSniffer.php:624 22.2183 12560080 7. PEAR_Sniffs_Commenting_FileCommentSniff->process() /usr/share/php/PHP/CodeSniffer/File.php:380 22.2184 12560732 8. PHP_CodeSniffer_File->addError() /usr/share/php/PHP/CodeSniffer/Standards/PEAR/Sniffs/Commenting/FileCommentSniff.php:177 Expected result: ---------------- a valid xml file Actual result: -------------- the xml file starting thith the Notice lines

Comments

 [2008-08-18 22:46 UTC] squiz (Greg Sherwood)
The error messages appear to be caused by a file containing only a PHP open tag.
 [2008-08-18 23:07 UTC] squiz (Greg Sherwood)
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.