Commit 5cf0afb
Convert array from AMQP 1.0 to AMQP 0.9.1
Fix the following crash when an AMQP 0.9.1 client consumes an AMQP 1.0
encoded message that contains an array value in message annotations:
```
crasher:
initial call: rabbit_channel:init/1
pid: <0.685.0>
registered_name: []
exception exit: {function_clause,
[{mc_amqpl,to_091,
[<<"x-array">>,
{array,utf8,[{utf8,<<"e1">>},{utf8,<<"e2">>}]}],
[{file,"mc_amqpl.erl"},{line,737}]},
{mc_amqpl,'-convert_from/3-fun-3-',1,
[{file,"mc_amqpl.erl"},{line,168}]},
{lists,filtermap_1,2,
[{file,"lists.erl"},{line,2279}]},
{mc_amqpl,convert_from,3,
[{file,"mc_amqpl.erl"},{line,158}]},
{mc,convert,3,[{file,"mc.erl"},{line,332}]},
{rabbit_channel,handle_deliver0,4,
[{file,"rabbit_channel.erl"},{line,2619}]},
{lists,foldl_1,3,[{file,"lists.erl"},{line,2151}]},
{lists,foldl,3,[{file,"lists.erl"},{line,2146}]}]}
```
(cherry picked from commit 814d44d)
# Conflicts:
# deps/amqp10_client/src/amqp10_msg.erl1 parent 1c271d7 commit 5cf0afb
File tree
4 files changed
+35
-5
lines changed- deps
- amqp10_client/src
- rabbit
- src
- test
4 files changed
+35
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
402 | 402 | | |
403 | 403 | | |
404 | 404 | | |
405 | | - | |
406 | | - | |
| 405 | + | |
| 406 | + | |
407 | 407 | | |
408 | 408 | | |
409 | 409 | | |
| |||
433 | 433 | | |
434 | 434 | | |
435 | 435 | | |
| 436 | + | |
436 | 437 | | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
437 | 446 | | |
438 | 447 | | |
439 | 448 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
754 | 754 | | |
755 | 755 | | |
756 | 756 | | |
757 | | - | |
| 757 | + | |
758 | 758 | | |
759 | | - | |
| 759 | + | |
| 760 | + | |
| 761 | + | |
| 762 | + | |
| 763 | + | |
| 764 | + | |
760 | 765 | | |
761 | 766 | | |
762 | 767 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1328 | 1328 | | |
1329 | 1329 | | |
1330 | 1330 | | |
| 1331 | + | |
| 1332 | + | |
| 1333 | + | |
| 1334 | + | |
| 1335 | + | |
| 1336 | + | |
| 1337 | + | |
1331 | 1338 | | |
1332 | 1339 | | |
1333 | 1340 | | |
| |||
1407 | 1414 | | |
1408 | 1415 | | |
1409 | 1416 | | |
| 1417 | + | |
| 1418 | + | |
| 1419 | + | |
| 1420 | + | |
| 1421 | + | |
| 1422 | + | |
| 1423 | + | |
1410 | 1424 | | |
1411 | 1425 | | |
1412 | 1426 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
532 | 532 | | |
533 | 533 | | |
534 | 534 | | |
535 | | - | |
| 535 | + | |
| 536 | + | |
536 | 537 | | |
537 | 538 | | |
538 | 539 | | |
| |||
598 | 599 | | |
599 | 600 | | |
600 | 601 | | |
| 602 | + | |
601 | 603 | | |
602 | 604 | | |
603 | 605 | | |
| |||
0 commit comments