diff options
author | Nayeem Rahman <nayeemrmn99@gmail.com> | 2020-05-29 16:27:43 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-29 17:27:43 +0200 |
commit | 8e39275429c36ff5dfa5d62a80713c5b288fe26a (patch) | |
tree | 1d6d2781682bed1c29f81366f08db65c604fef2c /cli/js/lib.deno.ns.d.ts | |
parent | ad6d2a7734aafb4a64837abc6abd1d1d0fb20017 (diff) |
fix(cli/permissions): Fix CWD and exec path leaks (#5642)
Diffstat (limited to 'cli/js/lib.deno.ns.d.ts')
-rw-r--r-- | cli/js/lib.deno.ns.d.ts | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/cli/js/lib.deno.ns.d.ts b/cli/js/lib.deno.ns.d.ts index fd0c0e6d7..74f1a2e15 100644 --- a/cli/js/lib.deno.ns.d.ts +++ b/cli/js/lib.deno.ns.d.ts @@ -897,7 +897,11 @@ declare namespace Deno { export interface MakeTempOptions { /** Directory where the temporary directory should be created (defaults to - * the env variable TMPDIR, or the system's default, usually /tmp). */ + * the env variable TMPDIR, or the system's default, usually /tmp). + * + * Note that if the passed `dir` is relative, the path returned by + * makeTempFile() and makeTempDir() will also be relative. Be mindful of + * this when changing working directory. */ dir?: string; /** String that should precede the random portion of the temporary * directory's name. */ @@ -1253,7 +1257,9 @@ declare namespace Deno { * console.log(realSymLinkPath); // outputs "/home/alice/file.txt" * ``` * - * Requires `allow-read` permission. */ + * Requires `allow-read` permission for the target path. + * Also requires `allow-read` permission for the CWD if the target path is + * relative.*/ export function realPathSync(path: string): string; /** Resolves to the absolute normalized path, with symbolic links resolved. @@ -1267,7 +1273,9 @@ declare namespace Deno { * console.log(realSymLinkPath); // outputs "/home/alice/file.txt" * ``` * - * Requires `allow-read` permission. */ + * Requires `allow-read` permission for the target path. + * Also requires `allow-read` permission for the CWD if the target path is + * relative.*/ export function realPath(path: string): Promise<string>; export interface DirEntry { |