Browse Source

reply with 'closed' on stop

Anton Lebedevich 13 years ago
parent
commit
d8aa6af2c4
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/pgsql_sock.erl

+ 1 - 1
src/pgsql_sock.erl

@@ -135,7 +135,7 @@ handle_cast(Req = {_, {connect, Host, Username, Password, Opts}}, State) ->
                   async = Async}};
                   async = Async}};
 
 
 handle_cast(stop, State) ->
 handle_cast(stop, State) ->
-    {stop, normal, flush_queue(State, {error, stop})};
+    {stop, normal, flush_queue(State, {error, closed})};
 
 
 handle_cast(Req = {_, {squery, Sql}}, State) ->
 handle_cast(Req = {_, {squery, Sql}}, State) ->
     #state{queue = Q} = State,
     #state{queue = Q} = State,