| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 4e49d5d commit 8d259e6
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -2598,7 +2598,7 @@ realpathSync.native = (path, options) => { | |||
| 2598 | 2598 | options = getOptions(options); | |
| 2599 | 2599 | path = getValidatedPath(path); | |
| 2600 | 2600 | const ctx = { path }; | |
| 2601 | - const result = binding.realpath(path, options.encoding, undefined, ctx); | ||
| 2601 | + const result = binding.realpath(pathModule.toNamespacedPath(path), options.encoding, undefined, ctx); | ||
| 2602 | 2602 | handleErrorFromBinding(ctx); | |
| 2603 | 2603 | return result; | |
| 2604 | 2604 | }; | |
@@ -2758,7 +2758,7 @@ realpath.native = (path, options, callback) => { | |||
| 2758 | 2758 | path = getValidatedPath(path); | |
| 2759 | 2759 | const req = new FSReqCallback(); | |
| 2760 | 2760 | req.oncomplete = callback; | |
| 2761 | - return binding.realpath(path, options.encoding, req); | ||
| 2761 | + return binding.realpath(pathModule.toNamespacedPath(path), options.encoding, req); | ||
| 2762 | 2762 | }; | |
| 2763 | 2763 | ||
| 2764 | 2764 | /** | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -43,4 +43,7 @@ console.log({ | |||
| 43 | 43 | ||
| 44 | 44 | fs.writeFile(fullPath, 'ok', common.mustSucceed(() => { | |
| 45 | 45 | fs.stat(fullPath, common.mustSucceed()); | |
| 46 | + | ||
| 47 | + // Tests https://github.com/nodejs/node/issues/39721 | ||
| 48 | + fs.realpath.native(fullPath, common.mustSucceed()); | ||
| 46 | 49 | })); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments