summaryrefslogtreecommitdiff
path: root/deps/npm/node_modules/graceful-fs
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2013-09-07 14:31:04 -0500
committerisaacs <i@izs.me>2013-09-07 14:31:04 -0500
commitebeae2df518af168a8ebd9117540238f0df916a3 (patch)
treeecfedcf075d58e910f520a42407876577e4fc617 /deps/npm/node_modules/graceful-fs
parent1be09dfc25816acc87d96f82348d3bb3844d328e (diff)
downloadnode-new-ebeae2df518af168a8ebd9117540238f0df916a3.tar.gz
npm: upgrade to 1.3.11
Diffstat (limited to 'deps/npm/node_modules/graceful-fs')
-rw-r--r--deps/npm/node_modules/graceful-fs/README.md13
-rw-r--r--deps/npm/node_modules/graceful-fs/graceful-fs.js11
-rw-r--r--deps/npm/node_modules/graceful-fs/package.json8
3 files changed, 16 insertions, 16 deletions
diff --git a/deps/npm/node_modules/graceful-fs/README.md b/deps/npm/node_modules/graceful-fs/README.md
index 01af3d6b63..eb1a109356 100644
--- a/deps/npm/node_modules/graceful-fs/README.md
+++ b/deps/npm/node_modules/graceful-fs/README.md
@@ -11,10 +11,9 @@ resilient to errors.
graceful-fs:
-* keeps track of how many file descriptors are open, and by default
- limits this to 1024. Any further requests to open a file are put in a
- queue until new slots become available. If 1024 turns out to be too
- much, it decreases the limit further.
+* Queues up `open` and `readdir` calls, and retries them once
+ something closes if there is an EMFILE error from too many file
+ descriptors.
* fixes `lchmod` for Node versions prior to 0.6.2.
* implements `fs.lutimes` if possible. Otherwise it becomes a noop.
* ignores `EINVAL` and `EPERM` errors in `chown`, `fchown` or
@@ -25,9 +24,3 @@ graceful-fs:
On Windows, it retries renaming a file for up to one second if `EACCESS`
or `EPERM` error occurs, likely because antivirus software has locked
the directory.
-
-## Configuration
-
-The maximum number of open file descriptors that graceful-fs manages may
-be adjusted by setting `fs.MAX_OPEN` to a different number. The default
-is 1024.
diff --git a/deps/npm/node_modules/graceful-fs/graceful-fs.js b/deps/npm/node_modules/graceful-fs/graceful-fs.js
index a46b5b2a18..1865f92cc0 100644
--- a/deps/npm/node_modules/graceful-fs/graceful-fs.js
+++ b/deps/npm/node_modules/graceful-fs/graceful-fs.js
@@ -126,8 +126,15 @@ function Req () {
}
Req.prototype.done = function (er, result) {
- // if an error, and the code is EMFILE, then get in the queue
- if (er && er.code === "EMFILE") {
+ var tryAgain = false
+ if (er) {
+ var code = er.code
+ var tryAgain = code === "EMFILE"
+ if (process.platform === "win32")
+ tryAgain = tryAgain || code === "OK"
+ }
+
+ if (tryAgain) {
this.failures ++
enqueue(this)
} else {
diff --git a/deps/npm/node_modules/graceful-fs/package.json b/deps/npm/node_modules/graceful-fs/package.json
index 4766b4b251..1b4a21c75a 100644
--- a/deps/npm/node_modules/graceful-fs/package.json
+++ b/deps/npm/node_modules/graceful-fs/package.json
@@ -6,7 +6,7 @@
},
"name": "graceful-fs",
"description": "A drop-in replacement for fs, making various improvements.",
- "version": "2.0.0",
+ "version": "2.0.1",
"repository": {
"type": "git",
"url": "git://github.com/isaacs/node-graceful-fs.git"
@@ -38,11 +38,11 @@
"EACCESS"
],
"license": "BSD",
- "readme": "# graceful-fs\n\ngraceful-fs functions as a drop-in replacement for the fs module,\nmaking various improvements.\n\nThe improvements are meant to normalize behavior across different\nplatforms and environments, and to make filesystem access more\nresilient to errors.\n\n## Improvements over fs module\n\ngraceful-fs:\n\n* keeps track of how many file descriptors are open, and by default\n limits this to 1024. Any further requests to open a file are put in a\n queue until new slots become available. If 1024 turns out to be too\n much, it decreases the limit further.\n* fixes `lchmod` for Node versions prior to 0.6.2.\n* implements `fs.lutimes` if possible. Otherwise it becomes a noop.\n* ignores `EINVAL` and `EPERM` errors in `chown`, `fchown` or\n `lchown` if the user isn't root.\n* makes `lchmod` and `lchown` become noops, if not available.\n* retries reading a file if `read` results in EAGAIN error.\n\nOn Windows, it retries renaming a file for up to one second if `EACCESS`\nor `EPERM` error occurs, likely because antivirus software has locked\nthe directory.\n\n## Configuration\n\nThe maximum number of open file descriptors that graceful-fs manages may\nbe adjusted by setting `fs.MAX_OPEN` to a different number. The default\nis 1024.\n",
+ "readme": "# graceful-fs\n\ngraceful-fs functions as a drop-in replacement for the fs module,\nmaking various improvements.\n\nThe improvements are meant to normalize behavior across different\nplatforms and environments, and to make filesystem access more\nresilient to errors.\n\n## Improvements over fs module\n\ngraceful-fs:\n\n* Queues up `open` and `readdir` calls, and retries them once\n something closes if there is an EMFILE error from too many file\n descriptors.\n* fixes `lchmod` for Node versions prior to 0.6.2.\n* implements `fs.lutimes` if possible. Otherwise it becomes a noop.\n* ignores `EINVAL` and `EPERM` errors in `chown`, `fchown` or\n `lchown` if the user isn't root.\n* makes `lchmod` and `lchown` become noops, if not available.\n* retries reading a file if `read` results in EAGAIN error.\n\nOn Windows, it retries renaming a file for up to one second if `EACCESS`\nor `EPERM` error occurs, likely because antivirus software has locked\nthe directory.\n",
"readmeFilename": "README.md",
"bugs": {
"url": "https://github.com/isaacs/node-graceful-fs/issues"
},
- "_id": "graceful-fs@2.0.0",
- "_from": "graceful-fs@2"
+ "_id": "graceful-fs@2.0.1",
+ "_from": "graceful-fs@~2.0.0"
}