Lines Matching refs:path
87 // Remove everything leading up to and including the final path separator.
737 // missing in the error messages. The path, dest, syscall, fd, .etc
749 req->path,
822 // Reverse the logic applied by path.toNamespacedPath() to create a
823 // namespace-prefixed path.
824 void FromNamespacedPath(std::string* path) {
826 if (path->compare(0, 8, "\\\\?\\UNC\\", 8) == 0) {
827 *path = path->substr(8);
828 path->insert(0, "\\\\");
829 } else if (path->compare(0, 4, "\\\\?\\", 4) == 0) {
830 *path = path->substr(4);
845 Local<Value> path;
849 &error).ToLocal(&path)) {
852 return req_wrap->Resolve(path);
866 req->path,
923 UVException(isolate, r, nullptr, req_wrap->syscall(), req->path));
956 BufferValue path(isolate, args[0]);
957 CHECK_NOT_NULL(*path);
960 if (req_wrap_async != nullptr) { // access(path, mode, req)
962 UV_FS_ACCESS, req_wrap_async, "path", TRACE_STR_COPY(*path))
964 uv_fs_access, *path, mode);
965 } else { // access(path, mode, undefined, ctx)
969 SyncCall(env, args[3], &req_wrap_sync, "access", uv_fs_access, *path, mode);
1007 node::Utf8Value path(isolate, args[0]);
1009 if (strlen(*path) != path.length()) {
1014 const int fd = uv_fs_open(loop, &open_req, *path, O_RDONLY, 0, nullptr);
1095 // Used to speed up module loading. Returns 0 if the path refers to
1102 node::Utf8Value path(env->isolate(), args[0]);
1105 int rc = uv_fs_stat(env->event_loop(), &req, *path, nullptr);
1122 BufferValue path(env->isolate(), args[0]);
1123 CHECK_NOT_NULL(*path);
1127 if (req_wrap_async != nullptr) { // stat(path, use_bigint, req)
1129 UV_FS_STAT, req_wrap_async, "path", TRACE_STR_COPY(*path))
1131 uv_fs_stat, *path);
1132 } else { // stat(path, use_bigint, undefined, ctx)
1136 int err = SyncCall(env, args[3], &req_wrap_sync, "stat", uv_fs_stat, *path);
1155 BufferValue path(env->isolate(), args[0]);
1156 CHECK_NOT_NULL(*path);
1160 if (req_wrap_async != nullptr) { // lstat(path, use_bigint, req)
1162 UV_FS_LSTAT, req_wrap_async, "path", TRACE_STR_COPY(*path))
1164 uv_fs_lstat, *path);
1165 } else { // lstat(path, use_bigint, undefined, ctx)
1170 *path);
1221 BufferValue path(env->isolate(), args[0]);
1222 CHECK_NOT_NULL(*path);
1226 if (req_wrap_async != nullptr) { // statfs(path, use_bigint, req)
1228 UV_FS_STATFS, req_wrap_async, "path", TRACE_STR_COPY(*path))
1236 *path);
1237 } else { // statfs(path, use_bigint, undefined, ctx)
1242 SyncCall(env, args[3], &req_wrap_sync, "statfs", uv_fs_statfs, *path);
1265 BufferValue path(isolate, args[1]);
1266 CHECK_NOT_NULL(*path);
1272 if (req_wrap_async != nullptr) { // symlink(target, path, flags, req)
1277 "path",
1278 TRACE_STR_COPY(*path))
1279 AsyncDestCall(env, req_wrap_async, args, "symlink", *path, path.length(),
1280 UTF8, AfterNoArgs, uv_fs_symlink, *target, *path, flags);
1281 } else { // symlink(target, path, flags, undefined, ctx)
1286 uv_fs_symlink, *target, *path, flags);
1331 BufferValue path(isolate, args[0]);
1332 CHECK_NOT_NULL(*path);
1337 if (req_wrap_async != nullptr) { // readlink(path, encoding, req)
1339 UV_FS_READLINK, req_wrap_async, "path", TRACE_STR_COPY(*path))
1341 uv_fs_readlink, *path);
1347 uv_fs_readlink, *path);
1481 BufferValue path(env->isolate(), args[0]);
1482 CHECK_NOT_NULL(*path);
1487 UV_FS_UNLINK, req_wrap_async, "path", TRACE_STR_COPY(*path))
1489 uv_fs_unlink, *path);
1494 SyncCall(env, args[2], &req_wrap_sync, "unlink", uv_fs_unlink, *path);
1505 BufferValue path(env->isolate(), args[0]);
1506 CHECK_NOT_NULL(*path);
1508 FSReqBase* req_wrap_async = GetReqWrap(args, 1); // rmdir(path, req)
1511 UV_FS_RMDIR, req_wrap_async, "path", TRACE_STR_COPY(*path))
1513 uv_fs_rmdir, *path);
1514 } else { // rmdir(path, undefined, ctx)
1519 uv_fs_rmdir, *path);
1526 const std::string& path,
1535 req_wrap->continuation_data()->PushPath(std::move(path));
1594 const char* path,
1602 req_wrap->continuation_data()->PushPath(std::move(path));
1612 std::string path = req->path;
1621 req_wrap->continuation_data()->MaybeSetFirstPath(path);
1624 req_wrap->continuation_data()->MaybeSetFirstPath(path);
1626 MKDirpAsync(loop, req, path.c_str(),
1638 std::string dirname = path.substr(0,
1639 path.find_last_of(kPathSeparator));
1640 if (dirname != path) {
1641 req_wrap->continuation_data()->PushPath(path);
1648 MKDirpAsync(loop, req, path.c_str(),
1656 int err = uv_fs_stat(loop, req, path.c_str(),
1665 std::string path = req->path;
1667 MKDirpAsync(loop, req, path.c_str(),
1673 // verify that the path pointed to is actually a directory.
1688 FSReqWrapSync* req_wrap, const char* path, int mode) {
1690 int err = MKDirpSync(env->event_loop(), &req_wrap->req, path, mode,
1712 BufferValue path(env->isolate(), args[0]);
1713 CHECK_NOT_NULL(*path);
1722 if (req_wrap_async != nullptr) { // mkdir(path, mode, req)
1724 UV_FS_UNLINK, req_wrap_async, "path", TRACE_STR_COPY(*path))
1727 mkdirp ? MKDirpAsync : uv_fs_mkdir, *path, mode);
1728 } else { // mkdir(path, mode, undefined, ctx)
1733 int err = CallMKDirpSync(env, args, &req_wrap_sync, *path, mode);
1739 MaybeLocal<Value> path = StringBytes::Encode(env->isolate(),
1742 if (path.IsEmpty()) {
1747 args.GetReturnValue().Set(path.ToLocalChecked());
1751 uv_fs_mkdir, *path, mode);
1764 BufferValue path(isolate, args[0]);
1765 CHECK_NOT_NULL(*path);
1770 if (req_wrap_async != nullptr) { // realpath(path, encoding, req)
1772 UV_FS_REALPATH, req_wrap_async, "path", TRACE_STR_COPY(*path))
1774 uv_fs_realpath, *path);
1775 } else { // realpath(path, encoding, undefined, ctx)
1780 uv_fs_realpath, *path);
1810 BufferValue path(isolate, args[0]);
1811 CHECK_NOT_NULL(*path);
1818 if (req_wrap_async != nullptr) { // readdir(path, encoding, withTypes, req)
1821 UV_FS_SCANDIR, req_wrap_async, "path", TRACE_STR_COPY(*path))
1829 *path,
1831 } else { // readdir(path, encoding, withTypes, undefined, ctx)
1836 uv_fs_scandir, *path, 0 /*flags*/);
1901 BufferValue path(env->isolate(), args[0]);
1902 CHECK_NOT_NULL(*path);
1911 if (req_wrap_async != nullptr) { // open(path, flags, mode, req)
1914 UV_FS_OPEN, req_wrap_async, "path", TRACE_STR_COPY(*path))
1916 uv_fs_open, *path, flags, mode);
1917 } else { // open(path, flags, mode, undefined, ctx)
1922 uv_fs_open, *path, flags, mode);
1937 BufferValue path(isolate, args[0]);
1938 CHECK_NOT_NULL(*path);
1947 if (req_wrap_async != nullptr) { // openFileHandle(path, flags, mode, req)
1949 UV_FS_OPEN, req_wrap_async, "path", TRACE_STR_COPY(*path))
1951 uv_fs_open, *path, flags, mode);
1952 } else { // openFileHandle(path, flags, mode, undefined, ctx)
1957 uv_fs_open, *path, flags, mode);
2178 uv_req->path = nullptr;
2316 /* fs.chmod(path, mode);
2325 BufferValue path(env->isolate(), args[0]);
2326 CHECK_NOT_NULL(*path);
2332 if (req_wrap_async != nullptr) { // chmod(path, mode, req)
2334 UV_FS_CHMOD, req_wrap_async, "path", TRACE_STR_COPY(*path))
2336 uv_fs_chmod, *path, mode);
2337 } else { // chmod(path, mode, undefined, ctx)
2342 uv_fs_chmod, *path, mode);
2379 /* fs.chown(path, uid, gid);
2388 BufferValue path(env->isolate(), args[0]);
2389 CHECK_NOT_NULL(*path);
2398 if (req_wrap_async != nullptr) { // chown(path, uid, gid, req)
2400 UV_FS_CHOWN, req_wrap_async, "path", TRACE_STR_COPY(*path))
2402 uv_fs_chown, *path, uid, gid);
2403 } else { // chown(path, uid, gid, undefined, ctx)
2408 uv_fs_chown, *path, uid, gid);
2454 BufferValue path(env->isolate(), args[0]);
2455 CHECK_NOT_NULL(*path);
2464 if (req_wrap_async != nullptr) { // lchown(path, uid, gid, req)
2466 UV_FS_LCHOWN, req_wrap_async, "path", TRACE_STR_COPY(*path))
2468 uv_fs_lchown, *path, uid, gid);
2469 } else { // lchown(path, uid, gid, undefined, ctx)
2474 uv_fs_lchown, *path, uid, gid);
2486 BufferValue path(env->isolate(), args[0]);
2487 CHECK_NOT_NULL(*path);
2496 if (req_wrap_async != nullptr) { // utimes(path, atime, mtime, req)
2498 UV_FS_UTIME, req_wrap_async, "path", TRACE_STR_COPY(*path))
2500 uv_fs_utime, *path, atime, mtime);
2501 } else { // utimes(path, atime, mtime, undefined, ctx)
2506 uv_fs_utime, *path, atime, mtime);
2547 BufferValue path(env->isolate(), args[0]);
2548 CHECK_NOT_NULL(*path);
2557 if (req_wrap_async != nullptr) { // lutimes(path, atime, mtime, req)
2559 UV_FS_LUTIME, req_wrap_async, "path", TRACE_STR_COPY(*path))
2561 uv_fs_lutime, *path, atime, mtime);
2562 } else { // lutimes(path, atime, mtime, undefined, ctx)
2567 uv_fs_lutime, *path, atime, mtime);
2587 UV_FS_MKDTEMP, req_wrap_async, "path", TRACE_STR_COPY(*tmpl))
2597 const char* path = req_wrap_sync.req.path;
2601 StringBytes::Encode(isolate, path, encoding, &error);