The following is the code that can run, and I want to change the strtok(buf, delim) to strsep(&ptr, delim) but it does not work. After the foll
strtok(buf, delim)
strsep(&ptr, delim)