summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2013-07-29 15:43:17 +0100
committerSimon MacMullen <simon@rabbitmq.com>2013-07-29 15:43:17 +0100
commit2a9af306d4afe7a3cbc83e8a0f0ae8b0b0a72487 (patch)
treece9d956278cb828442bf14a5121b87c690ac6b6e
parentb97d76ee28d152c558217241aae61e4fd11918f5 (diff)
parent0f4d07ed4964eac471bb07e78cd5e614d588d263 (diff)
downloadrabbitmq-server-2a9af306d4afe7a3cbc83e8a0f0ae8b0b0a72487.tar.gz
Merge bug25668
-rw-r--r--src/priority_queue.erl2
-rw-r--r--src/rabbit_reader.erl3
2 files changed, 4 insertions, 1 deletions
diff --git a/src/priority_queue.erl b/src/priority_queue.erl
index 0dc19819..18e1e8d9 100644
--- a/src/priority_queue.erl
+++ b/src/priority_queue.erl
@@ -51,7 +51,7 @@
-type(q() :: pqueue()).
-type(priority() :: integer() | 'infinity').
--type(squeue() :: {queue, [any()], [any()]}).
+-type(squeue() :: {queue, [any()], [any()], non_neg_integer()}).
-type(pqueue() :: squeue() | {pqueue, [{priority(), squeue()}]}).
-spec(new/0 :: () -> pqueue()).
diff --git a/src/rabbit_reader.erl b/src/rabbit_reader.erl
index 3cf88d06..0fa812c6 100644
--- a/src/rabbit_reader.erl
+++ b/src/rabbit_reader.erl
@@ -756,6 +756,9 @@ refuse_connection(Sock, Exception, {A, B, C, D}) ->
ok = inet_op(fun () -> rabbit_net:send(Sock, <<"AMQP",A,B,C,D>>) end),
throw(Exception).
+-ifdef(use_specs).
+-spec(refuse_connection/2 :: (rabbit_net:socket(), any()) -> no_return()).
+-endif.
refuse_connection(Sock, Exception) ->
refuse_connection(Sock, Exception, {0, 0, 9, 1}).