goto ret;
}
}
- n_max_chars -= (p - s);
- /* if (n_max_chars < 0) impossible */
store_param(s);
dbg_msg("args[]:'%s'", s);
+ n_max_chars -= (p - s);
+ /* if (n_max_chars < 0) impossible */
s = p;
n_max_arg--;
if (n_max_arg == 0 || n_max_chars == 0) {
goto ret;
}
}
- n_max_chars -= (p - s);
- /* if (n_max_chars < 0) impossible */
store_param(s);
dbg_msg("args[]:'%s'", s);
+ n_max_chars -= (p - s);
+ /* if (n_max_chars < 0) impossible */
s = p;
n_max_arg--;
if (n_max_arg == 0 || n_max_chars == 0) {
*p++ = c;
if (c == '\0') { /* word's delimiter or EOF detected */
/* A full word is loaded */
- n_max_chars -= (p - s);
- /* if (n_max_chars < 0) impossible */
store_param(s);
dbg_msg("args[]:'%s'", s);
- n_max_arg--;
+ n_max_chars -= (p - s);
+ /* if (n_max_chars < 0) impossible */
s = p;
+ n_max_arg--;
if (n_max_arg == 0 || n_max_chars == 0) {
goto ret;
}