diff options
author | Alan Antonuk <alan.antonuk@gmail.com> | 2014-08-02 21:52:09 -0700 |
---|---|---|
committer | Alan Antonuk <alan.antonuk@gmail.com> | 2014-08-02 21:52:09 -0700 |
commit | 45302cf00f6e585cba5ff1df6759de2c50e3d968 (patch) | |
tree | 026b56dc9bc0eb6350e4376daf543e8cbe5a79f5 /librabbitmq | |
parent | 4dc4eda0b0f87e903bbb67aab9a772a184bf3054 (diff) | |
download | rabbitmq-c-github-ask-45302cf00f6e585cba5ff1df6759de2c50e3d968.tar.gz |
FIX: don't range-check channel_ids.
Even if a channel_max is specified, channel_ids can be any number, so don't
range-check channel_ids received. At present this gets rabbitmq-c back into
compliance with the way the RabbitMQ broker works.
See issue #187, #195
To correctly enforce channel_max from the client side, rabbitmq-c would need to
track open channels, which is a bit more involved to do correctly.
Diffstat (limited to 'librabbitmq')
-rw-r--r-- | librabbitmq/amqp_connection.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/librabbitmq/amqp_connection.c b/librabbitmq/amqp_connection.c index cb82e46..88136cd 100644 --- a/librabbitmq/amqp_connection.c +++ b/librabbitmq/amqp_connection.c @@ -279,10 +279,6 @@ int amqp_handle_input(amqp_connection_state_t state, /* frame length is 3 bytes in */ channel = amqp_d16(raw_frame, 1); - if ((int)channel > state->channel_max) { - return AMQP_STATUS_BAD_AMQP_DATA; - } - state->target_size = amqp_d32(raw_frame, 3) + HEADER_SIZE + FOOTER_SIZE; |