Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int i, lastwasspace;
- i = 0;
- lastwasspace = 0;
- while (s && *s) {
- if (lastwasspace && !(isspace(s))) {
- argv[i++] = s;
- lastwasspace = 0;
- }
- if (isspace(s)) {
- lastwasspace = 1;
- s = 0;
- }
- s++;
- }
Add Comment
Please, Sign In to add comment