This is not a bug, it is expected & reasonable behaviour. The `-p DIR' and `--tmpdir[=DIR]' mktemp(1) options are the same, excepting that the <DIR> argument is mandatory for -p and optional for --tmpdir. (See the manpage (`man mktemp') or try `mktemp --help'.) That is, the following are equivalent:
mktemp -u -p / --tmpdir mktemp -u -p/ --tmpdir mktemp -u --tmpdir=/ --tmpdir mktemp -u -p / -p "${TMPDIR:-/tmp}" All print "FOO/tmp.<random-stuff>" where <FOO> is the value of TMPDIR (/tmp if not set (the usual case)). Clearly, the LAST (right→most) -p or --tmpdir option is being used, with all the preceding ones ignored. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1822269 Title: mktemp does not handle -p option when --tmpdir option goes after -p option To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/coreutils/+bug/1822269/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs