07-06-2005 07:18 PM
07-07-2005 12:21 AM
07-07-2005 01:45 AM
Seems that the problem is the definition of the destination array. Try using this modified version of your code:
int i;
char buff[128];
char *szStrArray[128];
for (i = 0; i < 128; i++) {
szStrArray[i] = malloc (20);
memset (szStrArray[i], 0, 20);
}
Fmt(buff, "%s<%s", "1.23,4.56");
Scan(buff,"%s>%s[xt44]%s", szStrArray[0], szStrArray[1]);
DebugPrintf ("Source: %s\nItem1 = %s\nItem2 = %s\n", buff, szStrArray[0], szStrArray[1]);