|
|
@ -41,8 +41,8 @@ system_get_state(State) -> |
|
|
|
{ok, State}. |
|
|
|
|
|
|
|
-spec system_terminate(term(), pid(), [], term()) -> none(). |
|
|
|
system_terminate(Reason, _Parent, _Debug, _State) -> |
|
|
|
exit(Reason). |
|
|
|
system_terminate(Reason, _Parent, _Debug, State) -> |
|
|
|
terminate(Reason, State). |
|
|
|
|
|
|
|
modInit(Parent, Args) -> |
|
|
|
case init(Args) of |
|
|
@ -59,7 +59,7 @@ loop(Parent, State) -> |
|
|
|
{system, From, Request} -> |
|
|
|
sys:handle_system_msg(Request, From, Parent, ?MODULE, [], {Parent, State}); |
|
|
|
{'EXIT', Parent, Reason} -> |
|
|
|
exit(Reason); |
|
|
|
terminate(Reason, State); |
|
|
|
Msg -> |
|
|
|
case handleMsg(Msg, State) of |
|
|
|
kpS -> |
|
|
@ -67,7 +67,7 @@ loop(Parent, State) -> |
|
|
|
{ok, NewState} -> |
|
|
|
loop(Parent, NewState); |
|
|
|
{stop, Reason} -> |
|
|
|
exit(Reason) |
|
|
|
terminate(Reason, State) |
|
|
|
end |
|
|
|
end. |
|
|
|
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% genActor end %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
|
|
@ -123,6 +123,9 @@ handleMsg({inet_async, LSock, Ref, Msg}, #state{lSock = LSock, ref = Ref, conMod |
|
|
|
handleMsg(_Msg, _State) -> |
|
|
|
kpS. |
|
|
|
|
|
|
|
terminate(Reason, _State) -> |
|
|
|
exit(Reason). |
|
|
|
|
|
|
|
newAsyncAccept(LSock, State) -> |
|
|
|
case prim_inet:async_accept(LSock, -1) of |
|
|
|
{ok, Ref} -> |
|
|
|