-
Simon McVittie authored
If we pass in SRT_RESOLVE_FLAGS_READABLE or SRT_RESOLVE_FLAGS_DIRECTORY, and something goes wrong while we are opening the file, then the best diagnostics libglnx can give us will be something like "openat(/proc/self/fd/21): <strerror result>", which is not very informative. Adding current_path turns this into something more like "Unable to open "foo/bar": openat(/proc/self/fd/21): <strerror result>", which gives us more hope of figuring it out. I originally suspected this was the error path being hit in <https://github.com/ValveSoftware/steam-runtime/issues/366 >, but now I think it probably isn't. Signed-off-by:
Simon McVittie <smcv@collabora.com>
Simon McVittie authoredIf we pass in SRT_RESOLVE_FLAGS_READABLE or SRT_RESOLVE_FLAGS_DIRECTORY, and something goes wrong while we are opening the file, then the best diagnostics libglnx can give us will be something like "openat(/proc/self/fd/21): <strerror result>", which is not very informative. Adding current_path turns this into something more like "Unable to open "foo/bar": openat(/proc/self/fd/21): <strerror result>", which gives us more hope of figuring it out. I originally suspected this was the error path being hit in <https://github.com/ValveSoftware/steam-runtime/issues/366 >, but now I think it probably isn't. Signed-off-by:
Simon McVittie <smcv@collabora.com>