php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #17257 Sort functions broken on 64bit platform
Submitted: 2002-05-15 14:09 UTC Modified: 2002-06-24 03:53 UTC
Votes:5
Avg. Score:4.8 ± 0.4
Reproduced:4 of 4 (100.0%)
Same Version:4 (100.0%)
Same OS:2 (50.0%)
From: mlong at mlong dot org Assigned:
Status: Closed Package: Scripting Engine problem
PHP Version: 4.2.1 OS: Compaq Tru64 5.1
Private report: No CVE-ID: None
 [2002-05-15 14:09 UTC] mlong at mlong dot org
In 4.2.1 I cannot get rsort or krsort to work. They worked fine in 4.1.2 with the same exact code.

I've written a script which shows it in both versions.
To view go to:
http://www.mlong.org/test.php

Patches

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-05-22 08:41 UTC] fcartegnie at nordnet dot fr
This is the same for asort & usort on linux platforms.
 [2002-05-22 15:49 UTC] mlong at mlong dot org
1. This worked under 4.1.2 but broke under 4.2.0rc1 so both 4.2.0 and 4.2.1 are broke
2. Tested rsort, krsort, arsort, uksort, sort. Even the examples given in documentation don't work anymore
3. I've tried it on three machines and it doesn't work on any of them
 [2002-05-22 15:49 UTC] mlong at mlong dot org
Just to clarify... every sort function is broke.
 [2002-05-24 05:18 UTC] fcartegnie at nordnet dot fr
Same as Bug #13307
 [2002-05-24 05:18 UTC] fcartegnie at nordnet dot fr
Forgot the line above. 
Same as Bug #17307
 [2002-06-01 10:25 UTC] mfischer@php.net
This is supposed to be fixed in HEAD, please try a snapshot from snaps.php.net (last thing I heard there was a pointer conversion problem).
 [2002-06-01 12:47 UTC] mlong at mlong dot org
I picked up the latest (200206010900) and could not get it to compile:

cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 2870: In this 
statement, the referenced type of the pointer value "psrc" is "const char", whic
h is not compatible with "const unsigned char" because they differ by signed/uns
igned attribute. (ptrmismatch1)
	p = psrc;
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 2887: In this 
statement, the referenced type of the pointer value "psrc" is "const char", whic
h is not compatible with "const unsigned char" because they differ by signed/uns
igned attribute. (ptrmismatch1)
	p = psrc;
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 6669: In this 
statement, the referenced type of the pointer value ""U+"" is "char", which is n
ot compatible with "const unsigned char" because they differ by signed/unsigned 
attribute. (ptrmismatch1)
				ret = mbfl_convert_filter_strcat(filter, "U+" TS
RMLS_CC);
-------------------------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 6675: In this 
statement, the referenced type of the pointer value ""JIS+"" is "char", which is
 not compatible with "const unsigned char" because they differ by signed/unsigne
d attribute. (ptrmismatch1)
						ret = mbfl_convert_filter_strcat
(filter, "JIS+" TSRMLS_CC);
--------------------------------------------------------------------------------
---------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 6678: In this 
statement, the referenced type of the pointer value ""JIS2+"" is "char", which i
s not compatible with "const unsigned char" because they differ by signed/unsign
ed attribute. (ptrmismatch1)
						ret = mbfl_convert_filter_strcat
(filter, "JIS2+" TSRMLS_CC);
--------------------------------------------------------------------------------
---------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 6681: In this 
statement, the referenced type of the pointer value ""W932+"" is "char", which i
s not compatible with "const unsigned char" because they differ by signed/unsign
ed attribute. (ptrmismatch1)
						ret = mbfl_convert_filter_strcat
(filter, "W932+" TSRMLS_CC);
--------------------------------------------------------------------------------
---------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 6684: In this 
statement, the referenced type of the pointer value ""I8859_1+"" is "char", whic
h is not compatible with "const unsigned char" because they differ by signed/uns
igned attribute. (ptrmismatch1)
						ret = mbfl_convert_filter_strcat
(filter, "I8859_1+" TSRMLS_CC);
--------------------------------------------------------------------------------
---------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 6687: In this 
statement, the referenced type of the pointer value ""?+"" is "char", which is n
ot compatible with "const unsigned char" because they differ by signed/unsigned 
attribute. (ptrmismatch1)
						ret = mbfl_convert_filter_strcat
(filter, "?+" TSRMLS_CC);
--------------------------------------------------------------------------------
---------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 6692: In this 
statement, the referenced type of the pointer value ""BAD+"" is "char", which is
 not compatible with "const unsigned char" because they differ by signed/unsigne
d attribute. (ptrmismatch1)
					ret = mbfl_convert_filter_strcat(filter,
 "BAD+" TSRMLS_CC);
--------------------------------------------------------------------------------
-^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 7471: In this 
statement, the referenced type of the pointer value "pc->needle.buffer" is "unsi
gned int", which is not compatible with "int" because they differ by signed/unsi
gned attribute. (ptrmismatch1)
			h = pc->needle.buffer;
------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 7476: In this 
statement, the referenced type of the pointer value "pc->needle.buffer" is "unsi
gned int", which is not compatible with "int" because they differ by signed/unsi
gned attribute. (ptrmismatch1)
				m = pc->needle.buffer;
--------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbfilter.c, line 8851: In this 
statement, the referenced type of the pointer value "&pd->tmpdev.buffer[pd->cspo
s]" is "unsigned char", which is not compatible with "const char" because they d
iffer by signed/unsigned attribute. (ptrmismatch1)
			encoding = mbfl_name2encoding(&pd->tmpdev.buffer[pd->csp
os]);
------------------------------------------------------^
cc  -Iext/mbstring/ -I/web/php4-200206010900/ext/mbstring/ -DPHP_ATOM_INC -I/web
/php4-200206010900/include -I/web/php4-200206010900/main -I/web/php4-20020601090
0 -I/web/php4-200206010900/Zend -I/usr/users/oracle/app/oracle/product/8.0.6/net
work/public -I/web/php4-200206010900/ext/xml/expat  -I/web/php4-200206010900/TSR
M -g  -c /web/php4-200206010900/ext/mbstring/mbstring.c -o ext/mbstring/mbstring
.o  && echo > ext/mbstring/mbstring.lo
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1236: In this 
statement, the referenced type of the pointer value "val_list[n]" is "char", whi
ch is not compatible with "unsigned char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
				string.val = val_list[n];
--------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1267: In this 
statement, the referenced type of the pointer value "val_list[n]" is "char", whi
ch is not compatible with "unsigned char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
		string.val = val_list[n];
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1270: In this 
statement, the referenced type of the pointer value "resvar.val" is "unsigned ch
ar", which is not compatible with "char" because they differ by signed/unsigned 
attribute. (ptrmismatch1)
			var = resvar.val;
------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1275: In this 
statement, the referenced type of the pointer value "val_list[n]" is "char", whi
ch is not compatible with "unsigned char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
		string.val = val_list[n];
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1278: In this 
statement, the referenced type of the pointer value "resval.val" is "unsigned ch
ar", which is not compatible with "char" because they differ by signed/unsigned 
attribute. (ptrmismatch1)
			val = resval.val;
------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1545: In this 
statement, the referenced type of the pointer value "str_list[n]" is "char", whi
ch is not compatible with "unsigned char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
				string.val = str_list[n];
--------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1584: In this 
statement, the referenced type of the pointer value "str_list[n]" is "char", whi
ch is not compatible with "unsigned char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
		string.val = str_list[n];
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1587: In this 
statement, the referenced type of the pointer value "resvar.val" is "unsigned ch
ar", which is not compatible with "char" because they differ by signed/unsigned 
attribute. (ptrmismatch1)
			var = resvar.val;
------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1593: In this 
statement, the referenced type of the pointer value "str_list[n]" is "char", whi
ch is not compatible with "unsigned char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
		string.val = str_list[n];
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1596: In this 
statement, the referenced type of the pointer value "resval.val" is "unsigned ch
ar", which is not compatible with "char" because they differ by signed/unsigned 
attribute. (ptrmismatch1)
			val = resval.val;
------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1688: In this 
statement, the referenced type of the pointer value "arg_string" is "char", whic
h is not compatible with "unsigned char" because they differ by signed/unsigned 
attribute. (ptrmismatch1)
 	string.val = arg_string;
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1696: In the i
nitializer for __s, the referenced type of the pointer value "(result.val)" is "
unsigned char", which is not compatible with "char" because they differ by signe
d/unsigned attribute. (ptrmismatch1)
 	RETVAL_STRINGL(result.val, result.len, 0);		/* the string is
 already strdup()'ed */
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1739: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1822: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	haystack.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1824: In this 
statement, the referenced type of the pointer value "(**arg2).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	needle.val = Z_STRVAL_PP(arg2);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1906: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	haystack.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1908: In this 
statement, the referenced type of the pointer value "(**arg2).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	needle.val = Z_STRVAL_PP(arg2);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 1962: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2002: In the i
nitializer for __s, the referenced type of the pointer value "(ret->val)" is "un
signed char", which is not compatible with "char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
		RETVAL_STRINGL(ret->val, ret->len, 0);		/* the string is
 already strdup()'ed */
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2052: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2086: In the i
nitializer for __s, the referenced type of the pointer value "(ret->val)" is "un
signed char", which is not compatible with "char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
		RETVAL_STRINGL(ret->val, ret->len, 0);		/* the string is
 already strdup()'ed */
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2113: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2182: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2204: In this 
statement, the referenced type of the pointer value "(**arg4).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
		marker.val = Z_STRVAL_PP(arg4);
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2210: In the i
nitializer for __s, the referenced type of the pointer value "(ret->val)" is "un
signed char", which is not compatible with "char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
		RETVAL_STRINGL(ret->val, ret->len, 0);		/* the string is
 already strdup()'ed */
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2250: In this 
statement, the referenced type of the pointer value "input" is "char", which is 
not compatible with "unsigned char" because they differ by signed/unsigned attri
bute. (ptrmismatch1)
	string.val = input;
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2298: In this 
statement, the referenced type of the pointer value "ret->val" is "unsigned char
", which is not compatible with "char" because they differ by signed/unsigned at
tribute. (ptrmismatch1)
		output = ret->val;
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2371: In this 
statement, the referenced type of the pointer value "&size" is "int", which is n
ot compatible with "unsigned long". (ptrmismatch)
	ret = php_mb_convert_encoding( Z_STRVAL_PP(arg_str), Z_STRLEN_PP(arg_str
), Z_STRVAL_PP(arg_new), _from_encodings, &size TSRMLS_CC);
--------------------------------------------------------------------------------
------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2445: In this 
statement, the referenced type of the pointer value "(**arg_str).value.str.val" 
is "char", which is not compatible with "unsigned char" because they differ by s
igned/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg_str);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2520: In this 
statement, the referenced type of the pointer value "(**argv[0]).value.str.val" 
is "char", which is not compatible with "unsigned char" because they differ by s
igned/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(argv[0]);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2524: In the i
nitializer for __s, the referenced type of the pointer value "(ret->val)" is "un
signed char", which is not compatible with "char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
		RETVAL_STRINGL(ret->val, ret->len, 0)	/* the string is already
 strdup()'ed */
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2548: In this 
statement, the referenced type of the pointer value "(**arg_str).value.str.val" 
is "char", which is not compatible with "unsigned char" because they differ by s
igned/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg_str);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2552: In the i
nitializer for __s, the referenced type of the pointer value "(ret->val)" is "un
signed char", which is not compatible with "char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
		RETVAL_STRINGL(ret->val, ret->len, 0)	/* the string is already
 strdup()'ed */
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2584: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2669: In the i
nitializer for __s, the referenced type of the pointer value "(ret->val)" is "un
signed char", which is not compatible with "char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
		RETVAL_STRINGL(ret->val, ret->len, 0);		/* the string is
 already strdup()'ed */
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2786: In this 
statement, the referenced type of the pointer value "(**hash_entry).value.str.va
l" is "char", which is not compatible with "unsigned char" because they differ b
y signed/unsigned attribute. (ptrmismatch1)
									string.v
al = Z_STRVAL_PP(hash_entry);
------------------------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2795: In this 
statement, the referenced type of the pointer value "(**args[n]).value.str.val" 
is "char", which is not compatible with "unsigned char" because they differ by s
igned/unsigned attribute. (ptrmismatch1)
						string.val = Z_STRVAL_PP(args[n]
);
------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2875: In this 
statement, the referenced type of the pointer value "(**hash_entry).value.str.va
l" is "char", which is not compatible with "unsigned char" because they differ b
y signed/unsigned attribute. (ptrmismatch1)
								string.val = Z_S
TRVAL_PP(hash_entry);
----------------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2880: In this 
statement, the referenced type of the pointer value "ret->val" is "unsigned char
", which is not compatible with "char" because they differ by signed/unsigned at
tribute. (ptrmismatch1)
									Z_STRVAL
_PP(hash_entry) = ret->val;
------------------------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2887: In this 
statement, the referenced type of the pointer value "(**var).value.str.val" is "
char", which is not compatible with "unsigned char" because they differ by signe
d/unsigned attribute. (ptrmismatch1)
					string.val = Z_STRVAL_PP(var);
----------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2892: In this 
statement, the referenced type of the pointer value "ret->val" is "unsigned char
", which is not compatible with "char" because they differ by signed/unsigned at
tribute. (ptrmismatch1)
						Z_STRVAL_PP(var) = ret->val;
------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2935: In this 
statement, the referenced type of the pointer value "(**arg1).value.str.val" is 
"char", which is not compatible with "unsigned char" because they differ by sign
ed/unsigned attribute. (ptrmismatch1)
	string.val = Z_STRVAL_PP(arg1);
--------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 2982: In the i
nitializer for __s, the referenced type of the pointer value "(ret->val)" is "un
signed char", which is not compatible with "char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
		RETVAL_STRINGL(ret->val, ret->len, 0);
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 3066: In this 
statement, the referenced type of the pointer value "(**argv[1]).value.str.val" 
is "char", which is not compatible with "unsigned char" because they differ by s
igned/unsigned attribute. (ptrmismatch1)
		orig_str.val = Z_STRVAL_PP(argv[1]);
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 3074: In this 
statement, the referenced type of the pointer value "pstr->val" is "unsigned cha
r", which is not compatible with "char" because they differ by signed/unsigned a
ttribute. (ptrmismatch1)
			subject_buf = subject = pstr->val;
--------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 3088: In this 
statement, the referenced type of the pointer value "(**argv[2]).value.str.val" 
is "char", which is not compatible with "unsigned char" because they differ by s
igned/unsigned attribute. (ptrmismatch1)
		orig_str.val = Z_STRVAL_PP(argv[2]);
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 3096: In this 
statement, the referenced type of the pointer value "pstr->val" is "unsigned cha
r", which is not compatible with "char" because they differ by signed/unsigned a
ttribute. (ptrmismatch1)
			message_buf = message = pstr->val;
--------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/mbstring.c, line 3133: In this 
statement, the referenced type of the pointer value "device.buffer" is "unsigned
 char", which is not compatible with "char" because they differ by signed/unsign
ed attribute. (ptrmismatch1)
	headers = device.buffer;
--------^
cc  -Iext/mbstring/ -I/web/php4-200206010900/ext/mbstring/ -DPHP_ATOM_INC -I/web
/php4-200206010900/include -I/web/php4-200206010900/main -I/web/php4-20020601090
0 -I/web/php4-200206010900/Zend -I/usr/users/oracle/app/oracle/product/8.0.6/net
work/public -I/web/php4-200206010900/ext/xml/expat  -I/web/php4-200206010900/TSR
M -g  -c /web/php4-200206010900/ext/mbstring/mbregex.c -o ext/mbstring/mbregex.o
  && echo > ext/mbstring/mbregex.lo
cc  -Iext/mbstring/ -I/web/php4-200206010900/ext/mbstring/ -DPHP_ATOM_INC -I/web
/php4-200206010900/include -I/web/php4-200206010900/main -I/web/php4-20020601090
0 -I/web/php4-200206010900/Zend -I/usr/users/oracle/app/oracle/product/8.0.6/net
work/public -I/web/php4-200206010900/ext/xml/expat  -I/web/php4-200206010900/TSR
M -g  -c /web/php4-200206010900/ext/mbstring/php_mbregex.c -o ext/mbstring/php_m
bregex.o  && echo > ext/mbstring/php_mbregex.lo
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 49: In this
 statement, the referenced type of the pointer value "(char ...)0" is "char", wh
ich is not compatible with "unsigned char" because they differ by signed/unsigne
d attribute. (ptrmismatch1)
		pd->buffer = (char*)0;
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 432: In thi
s statement, the referenced type of the pointer value "&string[pos]" is "char", 
which is not compatible with "const unsigned char" because they differ by signed
/unsigned attribute. (ptrmismatch1)
			php_mbregex_strbuf_ncat(&outdev, &string[pos], regs.beg[
0] - pos);
---------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 443: In thi
s statement, the referenced type of the pointer value "&string[regs.beg[n]]" is 
"char", which is not compatible with "const unsigned char" because they differ b
y signed/unsigned attribute. (ptrmismatch1)
						php_mbregex_strbuf_ncat(pdevice,
 &string[regs.beg[n]], regs.end[n] - regs.beg[n]);
--------------------------------------------------------------------------------
-^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 448: In thi
s statement, the referenced type of the pointer value "p" is "char", which is no
t compatible with "const unsigned char" because they differ by signed/unsigned a
ttribute. (ptrmismatch1)
					php_mbregex_strbuf_ncat(pdevice, p, 1);
-------------------------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 455: In thi
s statement, the referenced type of the pointer value """ is "char", which is no
t compatible with "const unsigned char" because they differ by signed/unsigned a
ttribute. (ptrmismatch1)
				php_mbregex_strbuf_ncat(&evaldev, "\0", 1);
------------------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 457: In thi
s statement, the referenced type of the pointer value "evaldev.buffer" is "unsig
ned char", which is not compatible with "char" because they differ by signed/uns
igned attribute. (ptrmismatch1)
				zend_eval_string(evaldev.buffer, &retval, descri
ption TSRMLS_CC);
-------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 460: In thi
s statement, the referenced type of the pointer value "retval.value.str.val" is 
"char", which is not compatible with "const unsigned char" because they differ b
y signed/unsigned attribute. (ptrmismatch1)
				php_mbregex_strbuf_ncat(&outdev, retval.value.st
r.val, retval.value.str.len);
-----------------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 473: In thi
s statement, the referenced type of the pointer value "&string[pos]" is "char", 
which is not compatible with "const unsigned char" because they differ by signed
/unsigned attribute. (ptrmismatch1)
			php_mbregex_strbuf_ncat(&outdev, &string[pos], string_le
n - pos);
---------------------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 485: In thi
s statement, the referenced type of the pointer value """ is "char", which is no
t compatible with "const unsigned char" because they differ by signed/unsigned a
ttribute. (ptrmismatch1)
	php_mbregex_strbuf_ncat(&outdev, "\0", 1);
-----------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 492: In the
 initializer for __s, the referenced type of the pointer value "(outdev.buffer)"
 is "unsigned char", which is not compatible with "char" because they differ by 
signed/unsigned attribute. (ptrmismatch1)
		RETVAL_STRINGL(outdev.buffer, n, 0);
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 719: In thi
s statement, the referenced type of the pointer value "(**(mbstring_globals.sear
ch_str)).value.str.val" is "char", which is not compatible with "unsigned char" 
because they differ by signed/unsigned attribute. (ptrmismatch1)
		str = Z_STRVAL_PP(MBSTRG(search_str));
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 738: In thi
s statement, the referenced type of the pointer value "str" is "unsigned char", 
which is not compatible with "const char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
	err = mbre_search(MBSTRG(search_re), str, len, pos, len - pos, MBSTRG(se
arch_regs));
---------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 765: In thi
s statement, the referenced type of the pointer value "&str[beg]" is "unsigned c
har", which is not compatible with "char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
						add_index_stringl(return_value, 
i, &str[beg], end - beg, 1);
--------------------------------------------------------------------------------
---^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 918: In thi
s statement, the referenced type of the pointer value "(**(mbstring_globals.sear
ch_str)).value.str.val" is "char", which is not compatible with "unsigned char" 
because they differ by signed/unsigned attribute. (ptrmismatch1)
		str = Z_STRVAL_PP(MBSTRG(search_str));
----------------^
cc: Warning: /web/php4-200206010900/ext/mbstring/php_mbregex.c, line 925: In thi
s statement, the referenced type of the pointer value "&str[beg]" is "unsigned c
har", which is not compatible with "char" because they differ by signed/unsigned
 attribute. (ptrmismatch1)
				add_index_stringl(return_value, i, &str[beg], en
d - beg, 1);
-------------------------------------------------------------------^
cc  -Iext/oci8/ -I/web/php4-200206010900/ext/oci8/ -DPHP_ATOM_INC -I/web/php4-20
0206010900/include -I/web/php4-200206010900/main -I/web/php4-200206010900 -I/web
/php4-200206010900/Zend -I/usr/users/oracle/app/oracle/product/8.0.6/network/pub
lic -I/web/php4-200206010900/ext/xml/expat  -I/web/php4-200206010900/TSRM -g  -c
 /web/php4-200206010900/ext/oci8/oci8.c -o ext/oci8/oci8.o  && echo > ext/oci8/o
ci8.lo
cc: Error: /web/php4-200206010900/ext/oci8/oci8.c, line 4243: In this statement,
 "OCI_ATTR_STATEMENT" is not declared. (undeclared)
			CALL_OCI_RETURN(statement->error, OCIAttrGet(
------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4660: In this statemen
t, the referenced type of the pointer value "(**arg).value.str.val" is "char", w
hich is not compatible with "const unsigned char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
			   CALL_OCI_RETURN(connection->error, OCIDateFromText(
---------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4691: In this statemen
t, the referenced type of the pointer value "(**arg).value.str.val" is "char", w
hich is not compatible with "const unsigned char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
			   CALL_OCI_RETURN(connection->error, OCIStringAssignTex
t(
---------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4816: In this statemen
t, the referenced type of the pointer value "&len" is "int", which is not compat
ible with "unsigned int" because they differ by signed/unsigned attribute. (ptrm
ismatch1)
			   CALL_OCI(OCIDateToText(
---------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4816: In this statemen
t, the referenced type of the pointer value "buff" is "char", which is not compa
tible with "unsigned char" because they differ by signed/unsigned attribute. (pt
rmismatch1)
			   CALL_OCI(OCIDateToText(
---------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4830: In the initializ
er for __s, the referenced type of the pointer value "(str)" is "unsigned char",
 which is not compatible with "char" because they differ by signed/unsigned attr
ibute. (ptrmismatch1)
			   RETURN_STRINGL(str,strlen(str),1);
---------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4830: In the initializ
er for __l, the referenced type of the pointer value "str" is "unsigned char", w
hich is not compatible with "const char" because they differ by signed/unsigned 
attribute. (ptrmismatch1)
			   RETURN_STRINGL(str,strlen(str),1);
---------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4965: In this statemen
t, the referenced type of the pointer value "(**val).value.str.val" is "char", w
hich is not compatible with "const unsigned char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
			   CALL_OCI_RETURN(connection->error, OCIDateFromText(
---------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4996: In this statemen
t, the referenced type of the pointer value "(**val).value.str.val" is "char", w
hich is not compatible with "const unsigned char" because they differ by signed/
unsigned attribute. (ptrmismatch1)
			   CALL_OCI_RETURN(connection->error, OCIStringAssignTex
t(
---------------------------^
*** Exit 1
Stop.
 [2002-06-01 12:53 UTC] mlong at mlong dot org
And if I try php4-STABLE-200206010900 I get:

Making all in Zend
yacc -p zend -v -d ./zend_language_parser.y -o zend_language_parser.c

 fatal error: invalid escape, or illegal reserved word: pure_parser, line 47
*** Exit 1
Stop.
*** Exit 1
Stop.
 [2002-06-01 15:37 UTC] mfischer@php.net
Can you try --without-mbstring and see if it compiles?

Changed category btw
 [2002-06-01 23:11 UTC] mlong at mlong dot org
[php4-STABLE-200206010900]

--enable-pcntl --enable-trans-sid --enable-ftp --without-mysql --enable-sockets
--with-oci8=/usr/users/oracle/app/oracle/product/8.0.6 --without-mbstring
noc03> make
Making all in Zend
yacc -p zend -v -d ./zend_language_parser.y -o zend_language_parser.c

 fatal error: invalid escape, or illegal reserved word: pure_parser, line 47
*** Exit 1
Stop.
*** Exit 1
Stop.

[php4-200206010900]

--enable-pcntl --enable-trans-sid --enable-ftp --without-mysql --enable-sockets
--with-oci8=/usr/users/oracle/app/oracle/product/8.0.6 --without-mbstring
noc03> make
/bin/cc -std0  -Iext/ctype/ -I/web/php4-200206010900/ext/ctype/ -DPHP_ATOM_INC -
I/web/php4-200206010900/include -I/web/php4-200206010900/main -I/web/php4-200206
010900 -I/web/php4-200206010900/Zend -I/usr/users/oracle/app/oracle/product/8.0.
6/network/public -I/web/php4-200206010900/ext/xml/expat  -I/web/php4-20020601090
0/TSRM -g  -c /web/php4-200206010900/ext/ctype/ctype.c -o ext/ctype/ctype.o  &&
echo > ext/ctype/ctype.lo
/bin/cc -std0  -Iext/ftp/ -I/web/php4-200206010900/ext/ftp/ -DPHP_ATOM_INC -I/we
b/php4-200206010900/include -I/web/php4-200206010900/main -I/web/php4-2002060109
00 -I/web/php4-200206010900/Zend -I/usr/users/oracle/app/oracle/product/8.0.6/ne
twork/public -I/web/php4-200206010900/ext/xml/expat  -I/web/php4-200206010900/TS
RM -g  -c /web/php4-200206010900/ext/ftp/php_ftp.c -o ext/ftp/php_ftp.o  && echo
 > ext/ftp/php_ftp.lo
/bin/cc -std0  -Iext/ftp/ -I/web/php4-200206010900/ext/ftp/ -DPHP_ATOM_INC -I/we
b/php4-200206010900/include -I/web/php4-200206010900/main -I/web/php4-2002060109
00 -I/web/php4-200206010900/Zend -I/usr/users/oracle/app/oracle/product/8.0.6/ne
twork/public -I/web/php4-200206010900/ext/xml/expat  -I/web/php4-200206010900/TS
RM -g  -c /web/php4-200206010900/ext/ftp/ftp.c -o ext/ftp/ftp.o  && echo > ext/f
tp/ftp.lo
/bin/cc -std0  -Iext/oci8/ -I/web/php4-200206010900/ext/oci8/ -DPHP_ATOM_INC -I/
web/php4-200206010900/include -I/web/php4-200206010900/main -I/web/php4-20020601
0900 -I/web/php4-200206010900/Zend -I/usr/users/oracle/app/oracle/product/8.0.6/
network/public -I/web/php4-200206010900/ext/xml/expat  -I/web/php4-200206010900/
TSRM -g  -c /web/php4-200206010900/ext/oci8/oci8.c -o ext/oci8/oci8.o  && echo >
 ext/oci8/oci8.lo
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 1351: In this statemen
t, the referenced type of the pointer value "memset(...)" is "signed char", whic
h is not compatible with "struct declared without a tag". (ptrmismatch)
        statement = ecalloc(1,sizeof(oci_statement));
--------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 2728: In this statemen
t, the referenced type of the pointer value "memset(...)" is "signed char", whic
h is not compatible with "struct declared without a tag". (ptrmismatch)
        define = ecalloc(1,sizeof(oci_define));
--------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 3092: In this statemen
t, & before array "buf" is ignored. (addrarray)
                while ((loblen = read(fp, &buf, sizeof(buf))) > 0) {
------------------------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 3093: In this statemen
t, & before array "buf" is ignored. (addrarray)
                        CALL_OCI_RETURN(connection->error, OCILobWrite(
------------------------^
cc: Error: /web/php4-200206010900/ext/oci8/oci8.c, line 4243: In this statement,
 "OCI_ATTR_STATEMENT" is not declared. (undeclared)
                        CALL_OCI_RETURN(statement->error, OCIAttrGet(
------------------------^
cc: Warning: /web/php4-200206010900/ext/oci8/oci8.c, line 4830: In the initializ
er for __s, the referenced type of the pointer value "(str)" is "unsigned char",
 which is not compatible with "signed char" because they differ by signed/unsign
ed attribute. (ptrmismatch1)
                           RETURN_STRINGL(str,strlen(str),1);
---------------------------^
*** Exit 1
Stop.
 [2002-06-01 23:52 UTC] mfischer@php.net
Mhmm .. I wonder if someone of the developers has actually access to such a machine to test it. Reopening.
 [2002-06-02 00:00 UTC] mlong at mlong dot org
If nobody has access to one then I'm sure I could setup a workstation that one of the developers could login to fix it.
 [2002-06-21 13:57 UTC] mlong at mlong dot org
Do any developers want to take me up on my offer to give a tru64 account so this bug can be fixed, and the development builds can be modified so they will compile properly?
 [2002-06-21 14:06 UTC] mfischer@php.net
There was some discussing lately and this note has been added to the documentat. Can you check if this actually applies to you (I hope you can read it and it doesn't get to badly wrapped) ?


+       If two members compare as equal, their order in the sorted array is undefined.                                                                           +       Up to PHP 4.0.6 the user defined functions would keep the original order for                                                                             +       thoes elements, but with the new sort algorithm intruduced with 4.1.0 this                                                                               +       is no longer the case as there is no solution to do so in an efficient way.            


Btw, about your compiler error: it seems this is related to oci8 (the rest is only warning but oci8 throws a real error from what I can read), so please disable this option as long as you're testing the sort functionality.
 [2002-06-21 14:07 UTC] mfischer@php.net
$%#^%^$%, here is the text, hopefully more readable:

If two members compare as equal, their order in
the sorted array is undefined.Up to PHP 4.0.6 the
user defined functions would keep the original
order for thoes elements, but with the new sort
algorithm intruduced with 4.1.0 this is no longer
the case as there is no solution to do so in an
efficient way.there is no solution to do so in an efficient way.way.            
 [2002-06-21 14:09 UTC] mlong at mlong dot org
I could look into that but since the non-user defined functions are also broken (sort, krsort, etc.) the problem is probably bigger than just the undefined comparison.

Also I did try without oci. In fact, I did a "./configure" and that is it for 200206210000 and I got:

yacc  /web/php4-200206210000/ext/standard/parsedate.y

 fatal error: invalid escape, or illegal reserved word: expect, line 184
*** Exit 1
Stop.

I'm not familar enough with yacc to fix it but I know 4.2.0 compiled OK.

Let me know if I can be of further assistance
 [2002-06-21 14:10 UTC] mlong at mlong dot org
Oh that yacc error was when I did a make...I was a bit vague in my last comment
 [2002-06-21 14:11 UTC] mfischer@php.net
What version of yacc is it, and is it GNU yacc ?
 [2002-06-21 15:01 UTC] mlong at mlong dot org
I'm not sure how to find out the version. It's not GNU it's compaq's which came with the OS. This particular system is running Compaq Tru64 UNIX V5.0A (Rev. 1094)
 [2002-06-21 15:14 UTC] mfischer@php.net
It's

$ yacc --version
GNU Bison version 1.28

on linux here.

Maybe you should consider installing the GNU version of that tool for use compiling PHP, I'm not aware of NON-GNU yacc's are even supported.
 [2002-06-21 15:34 UTC] mlong at mlong dot org
[root@wtpdev php4-200206210000]# yacc --version
usage: yacc -svdlt [-b prefix] [-p sym_prefix] [-P path] [-N num] file

Gotta love Compaq.  I am hesitant to do that because in the past PHP has always compiled on native Tru64 machines without the need to install any third party software.  I know Tru64 market share is doing down the drain but there are still a lot of machines out there.
 [2002-06-21 15:38 UTC] mfischer@php.net
Well, I think it won't bring us anywhere unless you try the GNU tools and see if it works.
 [2002-06-21 16:05 UTC] mlong at mlong dot org
Ok I installed GNU bison.

I now get this error when doing a make on latest php:

cc  -Imain/ -I/web/php4-200206210000/main/ -DPHP_ATOM_INC -I/web/php4-2002062100
00/include -I/web/php4-200206210000/main -I/web/php4-200206210000 -I/web/php4-20
0206210000/Zend -I/web/php4-200206210000/ext/xml/expat  -I/web/php4-200206210000
/TSRM -g  -c /web/php4-200206210000/main/memory_streams.c -o main/memory_streams
.o  && echo > main/memory_streams.lo
cc  -Imain/ -I/web/php4-200206210000/main/ -DPHP_ATOM_INC -I/web/php4-2002062100
00/include -I/web/php4-200206210000/main -I/web/php4-200206210000 -I/web/php4-20
0206210000/Zend -I/web/php4-200206210000/ext/xml/expat  -I/web/php4-200206210000
/TSRM -g  -c /web/php4-200206210000/main/user_streams.c -o main/user_streams.o
&& echo > main/user_streams.lo
Make: Don't know how to make /zend_language_parser.c.  Stop.
 [2002-06-21 16:20 UTC] venaas@php.net
The sort problem might be due to a bug in zend_qsort.
If you want to test this without fixing the build, you
could try to replace zend_qsort() with qsort() in the
relevant places, or test with the new zend_qsort() (it
was changed and hopefully fixed May 10, v1.5).
 [2002-06-21 17:33 UTC] mlong at mlong dot org
I took zend_qsort.h and zend_qsort.c from the latest build and put it into 4.2.0 and compiled it and that did indeed fix the problem.

An example ksort:
BEFORE p pineapples
BEFORE a apples
BEFORE o oranges
BEFORE b bananas
BEFORE g grapes
AFTER a apples
AFTER b bananas
AFTER g grapes
AFTER o oranges
AFTER p pineapples

So it looks like this bug can be closed. I do hope the compile problems are looked at before the next release but since every prior released (4.1.1, 4.2.0, etc.) has compiled without incident I have faith that will be taken care of.

Thanks for help...much appreciated.
 [2002-06-21 17:48 UTC] mfischer@php.net
I think it's best to open a new report about your compile problems so someone who can help finds it easier; just copy over all the relevant information.

Closing this bug due user request.
 [2002-06-24 03:53 UTC] sniper@php.net
The releases always have these bison/flex generated files
in them so you won't get those compile errors.

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Aug 16 23:01:28 2024 UTC