Repository: qpid-dispatch Updated Branches: refs/heads/master 6592d386b -> 57b2d6029
DISPATCH-207 - Allow empty message bodies. This will prevent dispatch router from displaying the 'Invalid body value' error Project: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/repo Commit: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/commit/57b2d602 Tree: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/tree/57b2d602 Diff: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/diff/57b2d602 Branch: refs/heads/master Commit: 57b2d6029e13d7676490810deae8a8c409fb35d8 Parents: 6592d38 Author: Ganesh Murthy <[email protected]> Authored: Fri Feb 5 13:44:49 2016 -0500 Committer: Ganesh Murthy <[email protected]> Committed: Tue Feb 23 08:33:21 2016 -0500 ---------------------------------------------------------------------- src/message.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/qpid-dispatch/blob/57b2d602/src/message.c ---------------------------------------------------------------------- diff --git a/src/message.c b/src/message.c index 4d2b3f6..f274912 100644 --- a/src/message.c +++ b/src/message.c @@ -318,8 +318,12 @@ static int qd_check_and_advance(qd_buffer_t **buffer, int pre_consume = 1; // Count the already extracted tag int consume = 0; unsigned char tag = next_octet(&test_cursor, &test_buffer); - if (!test_cursor) return 0; - switch (tag & 0xF0) { + + unsigned char tag_subcat = tag & 0xF0; + if (!test_cursor && tag_subcat != 0x40) + return 0; + + switch (tag_subcat) { case 0x40: break; case 0x50: consume = 1; break; case 0x60: consume = 2; break; --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
