Skip to content

glnx_file_copy_at: Add GLNX_FILE_COPY_NOCHOWN

Jonathan Lebon requested to merge jlebon/libglnx:pr/glnx-no-chown into master

In some contexts, we may want to copy a root-owned file but we're not running as root so we can't fchown it. (The case I'm interested in is actually a bit more obscure than this: running in a supermin VM as root, and wanting to copy a file we created onto a 9p mount where we don't have perms to fchown).

Add a GLNX_FILE_COPY_NOCHOWN to handle this case.

Merge request reports