6#if defined(DART_HOST_OS_LINUX) || defined(DART_HOST_OS_ANDROID)
24 cwdfd_ = dup(rootfd_);
32 cwdfd_ = dup(rootfd_);
42 intptr_t
rootfd()
const {
return rootfd_; }
43 char*
cwd()
const {
return cwd_; }
44 intptr_t
cwdfd()
const {
return cwdfd_; }
46 bool SetCwd(Namespace* namespc,
const char* new_path) {
47 NamespaceScope ns(namespc, new_path);
48 const intptr_t new_cwdfd =
59 tbuf.AddString(ns.path());
63 const intptr_t result_len =
86 NamespaceImpl* namespc_impl =
nullptr;
88 namespc_impl =
new NamespaceImpl(
namespc);
90 return new Namespace(namespc_impl);
94 return new Namespace(
new NamespaceImpl(path));
97Namespace::~Namespace() {
124void Namespace::ResolvePath(Namespace* namespc,
127 const char** resolved_path) {
129 ASSERT(resolved_path !=
nullptr);
132 *resolved_path =
path;
139 *resolved_path =
".";
142 *resolved_path = &
path[1];
146 *resolved_path =
path;
151 Namespace::ResolvePath(namespc,
path, &fd_, &path_);
static char * ScopedCopyCString(const char *str)
static bool IsAbsolutePath(const char *path)
static const char * PathSeparator()
static intptr_t CleanUnixPath(const char *in, char *out, intptr_t outlen)
NamespaceImpl(fdio_ns_t *fdio_ns)
bool SetCwd(Namespace *namespc, const char *new_path)
const char * path() const
NamespaceScope(Namespace *namespc, const char *path)
static bool IsDefault(Namespace *namespc)
static Namespace * Create(intptr_t namespc)
static const char * GetCurrent(Namespace *namespc)
NamespaceImpl * namespc() const
static intptr_t Default()
static bool SetCurrent(Namespace *namespc, const char *path)
static const uint8_t buffer[]
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
char * strdup(const char *str1)
#define NO_RETRY_EXPECTED(expression)
#define TEMP_FAILURE_RETRY(expression)