- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
const char *pS;
char *pD;
// clear out new string
szNew[0] = '\0';
pS = pszValue;
pD = szNew;
// step through the string, only copying back in characters that are printable
while( *pS )
{
if( ((byte)*pS) < 32 || ((byte)*pS) > 255 )
{
pS++;
continue;
}
*pD++ = *pS++;
}
// terminate the new string
*pD = '\0';
Комментарии (0) RSS