Commit 915f92b
committed
os/: modify getattrs to clear attrs out param before populating
Passing in a non-empty map would otherwise exhibit quite unexpected
behavior. For the bufferptr overload, any preexisting entries would
not be overwritten due to how std::map::emplace behaves. For the
bufferlist overload, it would result in appending to any pre-existing
entries.
The prior commit cleans up one such inadvertent caller which resulted
in the below bug.
Fixes: https://tracker.ceph.com/issues/65185
Signed-off-by: Samuel Just <[email protected]>1 parent 5671e85 commit 915f92b
2 files changed
+4
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
611 | 611 | | |
612 | 612 | | |
613 | 613 | | |
614 | | - | |
| 614 | + | |
615 | 615 | | |
616 | 616 | | |
617 | 617 | | |
| |||
622 | 622 | | |
623 | 623 | | |
624 | 624 | | |
625 | | - | |
| 625 | + | |
626 | 626 | | |
627 | 627 | | |
628 | 628 | | |
629 | 629 | | |
630 | 630 | | |
631 | 631 | | |
| 632 | + | |
632 | 633 | | |
633 | 634 | | |
634 | 635 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12426 | 12426 | | |
12427 | 12427 | | |
12428 | 12428 | | |
| 12429 | + | |
12429 | 12430 | | |
12430 | 12431 | | |
12431 | 12432 | | |
| |||
0 commit comments