Package: posh Severity: wishlist Currently posh creates heredocs in the filesystem. This means that heredoc contents will unnecessarily touch the disks, and it also means dealing with risky juggling of tempfile names.
It would be nicer, on platforms that support it, if posh could use memfd_create(2) for its heredocs. this appears to be done in the herein() function in exec.c. that code currently opens the same filename twice, once read-only, and then closes the read/write file descriptor. if posh uses memfd_create, it will get the file descriptor in read-write mode. once done writing, it should probably seek() back to offset 0, and somehow convert it to read-only (i don't know how to do that) before returning the file descriptor directly. --dkg