diff options
| author | Jean-Sebastien Pedron <jean-sebastien@rabbitmq.com> | 2014-11-24 12:25:34 +0100 |
|---|---|---|
| committer | Jean-Sebastien Pedron <jean-sebastien@rabbitmq.com> | 2014-11-24 12:25:34 +0100 |
| commit | d2416df1f97746646bf519f4af90a073efb4f86d (patch) | |
| tree | 30373c37b428093a2b3ca31b73bc1505856b10ea /src | |
| parent | f351d41768a2548fe35fee381c8ea0f2231ed377 (diff) | |
| download | rabbitmq-server-git-d2416df1f97746646bf519f4af90a073efb4f86d.tar.gz | |
Restore the "x-dead-letter-exchange" check lost in changeset 12133
Diffstat (limited to 'src')
| -rw-r--r-- | src/rabbit_amqqueue.erl | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/rabbit_amqqueue.erl b/src/rabbit_amqqueue.erl index 2e5a5e8c77..38c5c85507 100644 --- a/src/rabbit_amqqueue.erl +++ b/src/rabbit_amqqueue.erl @@ -466,6 +466,7 @@ check_arguments(QueueName, Args, Validators) -> declare_args() -> [{<<"x-expires">>, fun check_expires_arg/2}, {<<"x-message-ttl">>, fun check_message_ttl_arg/2}, + {<<"x-dead-letter-exchange">>, fun check_string_arg/2}, {<<"x-dead-letter-routing-key">>, fun check_dlxrk_arg/2}, {<<"x-max-length">>, fun check_non_neg_int_arg/2}, {<<"x-max-length-bytes">>, fun check_non_neg_int_arg/2}]. @@ -473,6 +474,9 @@ declare_args() -> consume_args() -> [{<<"x-priority">>, fun check_int_arg/2}, {<<"x-cancel-on-ha-failover">>, fun check_bool_arg/2}]. +check_string_arg({longstr, _}, _) -> ok; +check_string_arg({Type, _}, _) -> {error, {unacceptable_type, Type}}. + check_int_arg({Type, _}, _) -> case lists:member(Type, ?INTEGER_ARG_TYPES) of true -> ok; |
