diff options
author | Felix Fietkau <nbd@openwrt.org> | 2015-10-12 13:11:20 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2015-10-12 13:11:20 +0000 |
commit | 3758b86c3cca072cc344aa04f052fbf23e0179a9 (patch) | |
tree | 84f5727336df3fc62eb985ff36836bc582f1c014 /tools/firmware-utils | |
parent | 27ab75563d258bb7958622bff7e5919cba804c05 (diff) | |
download | master-187ad058-3758b86c3cca072cc344aa04f052fbf23e0179a9.tar.gz master-187ad058-3758b86c3cca072cc344aa04f052fbf23e0179a9.tar.bz2 master-187ad058-3758b86c3cca072cc344aa04f052fbf23e0179a9.zip |
firmware-utils/buffalo-enc: explicitly use signed char for checksum function
ARM defaults to unsigned char and that breaks the calculation, as it
relies on sign extension
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@47186 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'tools/firmware-utils')
-rw-r--r-- | tools/firmware-utils/src/buffalo-lib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/firmware-utils/src/buffalo-lib.c b/tools/firmware-utils/src/buffalo-lib.c index add3a7e023..b1d5ede0a2 100644 --- a/tools/firmware-utils/src/buffalo-lib.c +++ b/tools/firmware-utils/src/buffalo-lib.c @@ -179,7 +179,7 @@ int bcrypt_buf(unsigned char seed, unsigned char *key, unsigned char *src, uint32_t buffalo_csum(uint32_t csum, void *buf, unsigned long len) { - char *p = buf; + signed char *p = buf; while (len--) { int i; |