From e8b10a79c25e84f2a017e8a38b0725d8a0b259d3 Mon Sep 17 00:00:00 2001 From: isaacs Date: Sat, 18 Feb 2017 13:59:28 -0800 Subject: [PATCH] Retry on EBUSY et al on non-windows platforms as well --- rimraf.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rimraf.js b/rimraf.js index 5d9a576..e067516 100644 --- a/rimraf.js +++ b/rimraf.js @@ -85,7 +85,7 @@ function rimraf (p, options, cb) { results.forEach(function (p) { rimraf_(p, options, function CB (er) { if (er) { - if (isWindows && (er.code === "EBUSY" || er.code === "ENOTEMPTY" || er.code === "EPERM") && + if ((er.code === "EBUSY" || er.code === "ENOTEMPTY" || er.code === "EPERM") && busyTries < options.maxBusyTries) { busyTries ++ var time = busyTries * 100