Title: fs.mkdtemp should return a Buffer when prefix argument is a Buffer · Issue #58795 · nodejs/node · GitHub
Open Graph Title: fs.mkdtemp should return a Buffer when prefix argument is a Buffer · Issue #58795 · nodejs/node
X Title: fs.mkdtemp should return a Buffer when prefix argument is a Buffer · Issue #58795 · nodejs/node
Description: fs.mkdtemp and friends take a prefix argument, which can be a Buffer encoding a non-UTF8 path. But the APIs always return a string, which can mangle the encoding. So these should return a Buffer in that case. See #58516 (comment).
Open Graph Description: fs.mkdtemp and friends take a prefix argument, which can be a Buffer encoding a non-UTF8 path. But the APIs always return a string, which can mangle the encoding. So these should return a Buffer in...
X Description: fs.mkdtemp and friends take a prefix argument, which can be a Buffer encoding a non-UTF8 path. But the APIs always return a string, which can mangle the encoding. So these should return a Buffer in...
Opengraph URL: https://github.com/nodejs/node/issues/58795
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"fs.mkdtemp should return a Buffer when prefix argument is a Buffer","articleBody":"[`fs.mkdtemp`](https://nodejs.org/api/fs.html#fsmkdtempprefix-options-callback) and friends take a prefix argument, which can be a Buffer encoding a non-UTF8 path. But the APIs always return a string, which can mangle the encoding. So these should return a Buffer in that case. See https://github.com/nodejs/node/pull/58516#discussion_r2160220608.","author":{"url":"https://github.com/bakkot","@type":"Person","name":"bakkot"},"datePublished":"2025-06-22T20:27:03Z","url":"https://github.com/nodejs/node/issues/58795"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:d43f5506-d3c1-6a28-8c6c-02b431c946b9 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8054:2463B8:355181:453A84:6AED1DAC |
| html-safe-nonce | 4ea34600b9b70e95ac8bbda8ba0fd51f301a1c15bed494224f934273d204aec5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4MDU0OjI0NjNCODozNTUxODE6NDUzQTg0OjZBRUQxREFDIiwidmlzaXRvcl9pZCI6IjM3MTMwMTY1MTIxMzQzMjM2MjgiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | c2cd2c0d2c3ced7258d29470c9dccedfa677f47cfa58934232ea7d93a2c05bb6 |
| hovercard-subject-tag | issue:3166250818 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nodejs/node/58795/issue_layout |
| twitter:image | https://opengraph.githubassets.com/699bb6d5de41815ea127d0a66b732b1499fb659416036a120e34817ed66b0586/nodejs/node/issues/58795 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/699bb6d5de41815ea127d0a66b732b1499fb659416036a120e34817ed66b0586/nodejs/node/issues/58795 |
| og:image:alt | fs.mkdtemp and friends take a prefix argument, which can be a Buffer encoding a non-UTF8 path. But the APIs always return a string, which can mangle the encoding. So these should return a Buffer in... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | bakkot |
| hostname | github.com |
| expected-hostname | github.com |
| None | e3e0f7f63e50c6fe879198a93a0a023a648ecc0a5e9bc3b5e033ac57172237e6 |
| turbo-cache-control | no-preview |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 707a24b346ac8a82878b9c084efaa38a997660cb |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width