php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #29777 C++ comments in C code
Submitted: 2004-08-21 00:38 UTC Modified: 2004-08-21 02:02 UTC
From: akrosung at gmail dot com Assigned:
Status: Closed Package: Compile Failure
PHP Version: 5.0.1 OS: Solaris 9
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: akrosung at gmail dot com
New email:
PHP Version: OS:

 

 [2004-08-21 00:38 UTC] akrosung at gmail dot com
Description:
------------
Line 1103 in Installation directory $NSTALL_ROOT/php-5.0.1/Zend/zend_compile.c

lcname[sizeof(lcname)-1] = '\0'; // zend_str_tolower_copy won't necessarily set the zero byte/

Comment is in C++ format and crashes the "make"

Replaced the comment with /* .. */ enclosing it and it compiles fine.


Reproduce code:
---------------
Use Solaris 9 with apache 1.3.31  
Sun Forte 6 compilers

# ./configure
# make


Expected result:
----------------
...
Build complete.
(It is safe to ignore warnings about tempnam and tmpnam).



Actual result:
--------------
...
/opt/SUNWspro/bin/cc  -IZend/ -I/home/akrosung/INSTALL/newweb/php-5.0.1/Zend/ -DPHP_ATOM_INC -I/home/akrosung/INSTALL/newweb/php-5.0.1/include -I/home/akrosung/INSTALL/newweb/php-5.0.1/main -I/home/akrosung/INSTALL/newweb/php-5.0.1 -I/home/akrosung/INSTALL/newweb/php-5.0.1/Zend -I/usr/local/include/libxml2 -I/usr/local/include -I/usr/local/imap-2001a//include -I/usr/netscape/include -I/usr/local/mysql/include  -D_POSIX_PTHREAD_SEMANTICS -I/home/akrosung/INSTALL/newweb/php-5.0.1/TSRM  -g  -c /home/akrosung/INSTALL/newweb/php-5.0.1/Zend/zend_compile.c -o Zend/zend_compile.o  && echo > Zend/zend_compile.lo
"/home/akrosung/INSTALL/newweb/php-5.0.1/Zend/zend_compile.c", line 1103: syntax error before or at: /
"/home/akrosung/INSTALL/newweb/php-5.0.1/Zend/zend_compile.c", line 1103: newline in character constant
"/home/akrosung/INSTALL/newweb/php-5.0.1/Zend/zend_compile.c", line 1103: warning: character constant too long
"/home/akrosung/INSTALL/newweb/php-5.0.1/Zend/zend_compile.c", line 1108: cannot recover from previous errors
cc: acomp failed for /home/akrosung/INSTALL/newweb/php-5.0.1/Zend/zend_compile.c
*** Error code 2
make: Fatal error: Command failed for target `Zend/zend_compile.lo'

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-08-21 02:02 UTC] pollita@php.net
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Sep 11 00:01:28 2024 UTC