catch badarg exceptions on invalid callback procs
This commit is contained in:
parent
9b66894dda
commit
4ff4711d4f
|
@ -173,4 +173,8 @@ calc_checksum(Data) ->
|
|||
callback(undefined, IQRes, Fun) ->
|
||||
Fun(IQRes);
|
||||
callback(Proc, IQRes, Ctx) ->
|
||||
catch Proc ! {iq_reply, IQRes, Ctx}.
|
||||
try
|
||||
Proc ! {iq_reply, IQRes, Ctx}
|
||||
catch _:badarg ->
|
||||
ok
|
||||
end.
|
||||
|
|
Loading…
Reference in New Issue