for (char *p = strchr(tmpfn, ' '); p && *p; p = strchr(tmpfn, ' ')) *p = '_';
char *p; while (p = strchr(tmpfn, ' ')) *p = '_';
char *cp = NULL; for(cp = tmpfn; cp && *cp; cp++) if(isspace(*cp)) *cp = '_';
my brain too
Cool. But what does this have to do with the article? (I apologize if I'm missing something, it is 3am afterall)
Kids these days.