int wopen(const wcstring &pathname, int flags, mode_t mode) { // off the main thread, always use wopen_cloexec ASSERT_IS_MAIN_THREAD(); ASSERT_IS_NOT_FORKED_CHILD(); return wopen_internal(pathname, flags, mode, false); }
int wopen_cloexec(const wcstring &pathname, int flags, mode_t mode) { return wopen_internal(pathname, flags, mode, true); }