i don't really care for the utility of -p but it seems to be working as
advertised
try something like: mktemp myprefix "$PWD" or mktemp "" "$PWD"

mktemp --?p
  -p, --default=directory
                  Use directory if the TMPDIR environment variable is not
defined. Implies --tmp.

gnu man mktemp
       -p DIR use DIR as a prefix; implies -t [deprecated]

       -t     interpret TEMPLATE as a single file name component, relative
to a directory: $TMPDIR, if set; else  the
              directory specified via -p; else /tmp [deprecated]



On Tue, Dec 3, 2013 at 6:28 AM, Simon Toedt <simon.to...@gmail.com> wrote:

> I think I found a bug in mktemp(1)'s -p option:
> If I use mktemp(1) with -p in an O_XATTR directory it returns a path
> in /tmp instead:
>
> /bin/ksh -c 'builtin mktemp ; touch x1 ; cd -@ x1 ; mktemp -p "$PWD" ;
> :'
> /tmp/tmp246Y9N0.EZ3
>
> I would've expected the path to be like this one:
> /dev/file/xattr@/home/stoe/x1//@//tmp246Y9N0.EZ3
>
> Simon
> _______________________________________________
> ast-users mailing list
> ast-us...@lists.research.att.com
> http://lists.research.att.com/mailman/listinfo/ast-users
>
_______________________________________________
ast-developers mailing list
ast-developers@lists.research.att.com
http://lists.research.att.com/mailman/listinfo/ast-developers

Reply via email to