Skip to content
Browse files

Make passive mode default.

  • Loading branch information...
1 parent 6239214 commit 78f5d0b884e63a0c7520ccce4d1518b48be0035f @okeuday okeuday committed Mar 29, 2011
Showing with 3 additions and 2 deletions.
  1. +3 −2 src/erlzmq.erl
View
5 src/erlzmq.erl
@@ -98,8 +98,9 @@ socket(Context, [H | _] = L) ->
% active is not used for these socket types
erlzmq_nif:socket(Context, socket_type(H), 0);
false ->
- % active is true by default, like normal Erlang sockets
- erlzmq_nif:socket(Context, socket_type(H), 1)
+ % active is false by default
+ % (to avoid latency on small messages (messages < 32KB))
+ erlzmq_nif:socket(Context, socket_type(H), 0)
end.
%% @doc Accept connections on a socket.

0 comments on commit 78f5d0b

Please sign in to comment.
Something went wrong with that request. Please try again.