cleanup while trying to make sense of this code; (char*) sizeof(long)? what?

This commit is contained in:
Glenn Maynard
2004-07-22 19:20:31 +00:00
parent be87e21f9d
commit 181b6b5bc8
+5 -4
View File
@@ -72,12 +72,13 @@ char* _tcsechr( const char* psz, int ch, int escape )
// Coder Date Desc
// bro 2002-10-29
//========================================================
int _tcselen( int escape, char* srt, char* end = NULL )
int _tcselen( int escape, const char *srt, const char *end )
{
int len = 0;
char* pch = srt;
if( end==NULL ) end = (char*)sizeof(long);
char* prev_escape = NULL;
const char *pch = srt;
if( end==NULL )
end = (char*) sizeof(long);
const char *prev_escape = NULL;
while( pch && *pch && pch<end )
{
if( *pch == escape && prev_escape == NULL )