Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mount.zfs: use getopt_long instead of getopt to guarantee permutation…
… of argv. mount.zfs is called by convention (and util-linux) with arguments last, i.e. % mount.zfs <dataset> <mountpoint> -o <options> This is not a problem on glibc since GNU getopt(3) will reorder the arguments. However, alternative libc such as musl libc (or glibc with $POSIXLY_CORRECT set) will not permute argv and fail to parse the -o <options>. Use getopt_long so musl will permute arguments. Signed-off-by: Christian Neukirchen <chneukirchen@gmail.com> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes #4222
- Loading branch information