string1++;string2++;

Konstantin the_pleiades@comtv.ru
Thu Sep 7 21:14:00 GMT 2006


Hi!
Why there are no problems with this code in gcc?  

int Q_StringSort(const void *string1, const void *string2)
{
if(*(char *)string1 < *(char *)string2)
return -1;
else if(*(char *)string1 == *(char *)string2) {
while(*(char *)string1) {
string1++;  //MS VC have got error  size unknown
string2++;  //MS VC have got error  size unknown
if(*(char *)string1 < *(char *)string2)
return -1;
else if(*(char *)string1 == *(char *)string2) {
;
} else
return 1;
}
return 0;
} else
return 1;
}



More information about the Gcc-help mailing list