为什么这不起作用?
short pStringCt = 0;
const char* constInBuf = ibuf;
int j;
for (j = 0; j < i; j++)
{
    /*Detect when there's a space in the buffer and grab word*/
    if (ibuf[j] == ' ' ||
        ibuf[j] == '|' ||
        j == i - 1)
        {
            int k;
            for (k = j - 1; k >= 0; k--){
                if (k == 0 || ibuf[k] == ' ' || ibuf[k] == '|')
                {
                    if (pStringCt > 0){
                        pString[pStringCt] = strndup(constInBuf + k + 1, j - k + 1);
                        printf("-pString at %d is: %s\n", pStringCt, pString[pStringCt]);
                        pStringCt += 1;
                    }
                    if (pStringCt == 0){
                        pString[pStringCt] = strndup(constInBuf+k, j-k + 1);
                        printf("-----pString at %d is: %s\n", pStringCt, pString[pStringCt]);
                        pStringCt+=1;
                    }
                    printf("%d is pStringCt\n", pStringCt);
                    break;
                }
            }
        }
在 break 语句之后 pStringCt 的值没有增加。换言之,pStringCt 在方法开始时为 0。然后,它在与其相关的两个 if 语句之后增加到一个。但是在break语句之后,它重置为零......