Exit with timeout instead of returning an atom Every function that called `rexi:stream/1` had to check the return value for timeout and would then call `erlang:exit/1` if that atom were returned. Rather than force every function to make this check this just calls exit in `rexi:stream/1`. Its possible to catch this if a process ever happens to require it.
BugzId: 22729 Project: http://git-wip-us.apache.org/repos/asf/couchdb-rexi/repo Commit: http://git-wip-us.apache.org/repos/asf/couchdb-rexi/commit/945bfcac Tree: http://git-wip-us.apache.org/repos/asf/couchdb-rexi/tree/945bfcac Diff: http://git-wip-us.apache.org/repos/asf/couchdb-rexi/diff/945bfcac Branch: refs/heads/windsor-merge Commit: 945bfcac25007518f39cfbc6eb61d6d67773f598 Parents: 8f2c295 Author: Paul J. Davis <[email protected]> Authored: Fri Sep 6 15:04:00 2013 -0500 Committer: Robert Newson <[email protected]> Committed: Wed Jul 23 17:58:14 2014 +0100 ---------------------------------------------------------------------- src/rexi.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/couchdb-rexi/blob/945bfcac/src/rexi.erl ---------------------------------------------------------------------- diff --git a/src/rexi.erl b/src/rexi.erl index 75bc9bf..20f582b 100644 --- a/src/rexi.erl +++ b/src/rexi.erl @@ -181,7 +181,7 @@ stream(Msg, Limit, Timeout) -> erlang:send(Caller, {rexi, Ref, self(), Msg}), ok catch throw:timeout -> - timeout + exit(timeout) end. %% @equiv stream_ack(Client, 1)
