mirror of
https://git.busybox.net/busybox
synced 2026-01-31 16:43:21 +00:00
Force optind=1 for libc5 when doing cp in cp_mv.c
This commit is contained in:
parent
285b446d17
commit
2da90d3b58
1 changed files with 4 additions and 0 deletions
4
cp_mv.c
4
cp_mv.c
|
|
@ -214,6 +214,10 @@ extern int cp_mv_main(int argc, char **argv)
|
|||
usage(cp_mv_usage[dz_i]);
|
||||
}
|
||||
} else { /* (dz_i == is_mv) */
|
||||
/* Initialize optind to 1, since in libc5 optind
|
||||
* is not initialized until getopt() is called
|
||||
* (or until sneaky programmers force it...). */
|
||||
optind = 1;
|
||||
recursiveFlag = preserveFlag = TRUE;
|
||||
followLinks = FALSE;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue