Bug #4755
rgw: assumption of signed char
0%
Description
I'm testing ceph on an armhf based server. During compilation (from Debianized sources you provide), it turns out that in src/rgw/rgw_common.cc function url_decode(), there is an assumption that "char" is signed. That quite weird quirk is common to i386 and amd64, but on some other architectures, including arm*, "char" is unsigned.
A ham-fisted patch attached. I haven't actually tested it yet, but it compiles and looks kosher. In fact, the function above it, hex_to_num() has an obvious related bug in places where char is not unsigned (ie, not on arm), unless that data is validated somewhere else.
History
#1 Updated by Adam Borowski almost 11 years ago
Doh, in the title, s/patch/char/, of course.
#2 Updated by Yehuda Sadeh almost 11 years ago
- Project changed from Ceph to rgw
- Subject changed from assumption of signed patch to rgw: assumption of signed patch
#3 Updated by Ian Colle almost 11 years ago
- Subject changed from rgw: assumption of signed patch to rgw: assumption of signed char
#4 Updated by Yehuda Sadeh almost 11 years ago
- Target version set to v0.61 - Cuttlefish
#5 Updated by Ian Colle almost 11 years ago
- Tracker changed from Fix to Bug
- Target version deleted (
v0.61 - Cuttlefish)
#6 Updated by Ian Colle almost 11 years ago
- Assignee set to Yehuda Sadeh
- Target version set to v0.61 - Cuttlefish
#7 Updated by Yehuda Sadeh almost 11 years ago
Adam, I pushed a different fix to wip-4755 branch. Can you test it and make sure that it fixes the issue for you?
#8 Updated by Sage Weil almost 11 years ago
- Status changed from New to Resolved