You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Previous code used to call "defer f.Close()" on handles immediately after
an open operation before checking if the open succeeded. This caused the
code to attempt a close operation on invalid handles, which in the case of
the mount operation on a non-existent mount point, caused sandboxfs to
crash.
Fix this by simply moving the "defer f.Close()" statements after their
corresponding error checks, and add tests to ensure sandboxfs does not
misbehave in any of these cases.
As part of this change, we have unconvered another behavioral difference
between Linux and macOS: on the former, a missing mount point causes the
mount operation to fail (as it should) but, on the latter, OSXFUSE silently
creates the mount point. To resolve this difference and unify behaviors,
we now explicitly test for the existence of the mount point prior to
attemting the mount operation.
Based on Pallav Agarwal's patch in PR #1. Closes#1.
PiperOrigin-RevId: 169237923
At least to trim out the
/bazel-*
intermediates.The text was updated successfully, but these errors were encountered: