aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/src
diff options
context:
space:
mode:
authorChristopher Faulet <[email protected]>2011-09-06 11:10:43 +0200
committerHenrik Nord <[email protected]>2011-10-10 17:36:40 +0200
commit2c4e984bd1d75524fd6444dc2032f8d758a945ae (patch)
tree7249ef287033d773d163f8a9f18a09195395551c /lib/stdlib/src
parenteb9656c94f4e92c2a4875dc628cb41d283dd4d2b (diff)
downloadotp-2c4e984bd1d75524fd6444dc2032f8d758a945ae.tar.gz
otp-2c4e984bd1d75524fd6444dc2032f8d758a945ae.tar.bz2
otp-2c4e984bd1d75524fd6444dc2032f8d758a945ae.zip
Allow an infinite timeout to shutdown worker processes
Now, in child specification, the shutdown value can also be set to infinity for worker children. This restriction was removed because this is not always possible to predict the shutdown time for a worker. This is highly application-dependent.
Diffstat (limited to 'lib/stdlib/src')
-rw-r--r--lib/stdlib/src/supervisor.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/stdlib/src/supervisor.erl b/lib/stdlib/src/supervisor.erl
index 9da0d52f8c..051dca462b 100644
--- a/lib/stdlib/src/supervisor.erl
+++ b/lib/stdlib/src/supervisor.erl
@@ -1053,7 +1053,7 @@ validRestartType(RestartType) -> throw({invalid_restart_type, RestartType}).
validShutdown(Shutdown, _)
when is_integer(Shutdown), Shutdown > 0 -> true;
-validShutdown(infinity, supervisor) -> true;
+validShutdown(infinity, _) -> true;
validShutdown(brutal_kill, _) -> true;
validShutdown(Shutdown, _) -> throw({invalid_shutdown, Shutdown}).