diff options
author | Paul Joseph Davis <davisp@apache.org> | 2011-04-23 00:59:25 +0000 |
---|---|---|
committer | Paul Joseph Davis <davisp@apache.org> | 2011-04-23 00:59:25 +0000 |
commit | d47d7e98819363e31f81a7954fed8bccc5d7d03b (patch) | |
tree | c1573265174bca93ecf17c1d616ad64272e1099a /src/couchdb | |
parent | d277f7173a10910cab990b5b18e7b01bfc5034f2 (diff) |
Fix random errors in 173-os-daemon-cfg-register.t
This is a backport of 1096098 from trunk.
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1096099 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/couchdb')
-rw-r--r-- | src/couchdb/couch_os_daemons.erl | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/couchdb/couch_os_daemons.erl b/src/couchdb/couch_os_daemons.erl index bdd39997..d03f550c 100644 --- a/src/couchdb/couch_os_daemons.erl +++ b/src/couchdb/couch_os_daemons.erl @@ -86,12 +86,12 @@ handle_info({'EXIT', Port, Reason}, Table) -> ?LOG_INFO("Port ~p exited after stopping: ~p~n", [Port, Reason]); [#daemon{status=stopping}] -> true = ets:delete(Table, Port); - [#daemon{name=Name, status=restarting, errors=Errs}=D] -> + [#daemon{name=Name, status=restarting}=D] -> ?LOG_INFO("Daemon ~P restarting after config change.", [Name]), true = ets:delete(Table, Port), {ok, Port2} = start_port(D#daemon.cmd), true = ets:insert(Table, D#daemon{ - port=Port2, status=running, kill=undefined, errors=Errs, buf=[] + port=Port2, status=running, kill=undefined, buf=[] }); [#daemon{name=Name, status=halted}] -> ?LOG_ERROR("Halted daemon process: ~p", [Name]); @@ -106,12 +106,12 @@ handle_info({Port, {exit_status, Status}}, Table) -> [] -> ?LOG_ERROR("Unknown port ~p exiting ~p", [Port, Status]), {stop, {error, unknown_port_died, Status}, Table}; - [#daemon{name=Name, status=restarting, errors=Errors}=D] -> + [#daemon{name=Name, status=restarting}=D] -> ?LOG_INFO("Daemon ~P restarting after config change.", [Name]), true = ets:delete(Table, Port), {ok, Port2} = start_port(D#daemon.cmd), true = ets:insert(Table, D#daemon{ - port=Port2, kill=undefined, errors=Errors, buf=[] + port=Port2, status=running, kill=undefined, buf=[] }), {noreply, Table}; [#daemon{status=stopping}=D] -> @@ -140,7 +140,8 @@ handle_info({Port, {exit_status, Status}}, Table) -> true = ets:delete(Table, Port), {ok, Port2} = start_port(D#daemon.cmd), true = ets:insert(Table, D#daemon{ - port=Port2, kill=undefined, errors=Errors, buf=[] + port=Port2, status=running, kill=undefined, + errors=Errors, buf=[] }), {noreply, Table} end; |