summaryrefslogtreecommitdiffstats
path: root/axutils.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2007-01-23 12:17:04 +0000
committerRalf Baechle <ralf@linux-mips.org>2007-01-23 12:17:04 +0000
commitb5682742ef212b62c9494a2d462654a7d0301266 (patch)
treeb984478563194b90d6b8795f77e3223c6b8db9eb /axutils.c
parent93fd2c0b9476ed275d6f9597097cf266a315f84c (diff)
Fix pile of warnings about differing signedness. One of them looks
like a real buglet for some architectures.
Diffstat (limited to 'axutils.c')
-rw-r--r--axutils.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/axutils.c b/axutils.c
index b69a910..0e8f806 100644
--- a/axutils.c
+++ b/axutils.c
@@ -284,11 +284,14 @@ int rose_cmp(const rose_address *a, const rose_address *b)
*/
int ax25_validate(const char *call)
{
- unsigned char s[7];
+ unsigned char c;
+ char s[7];
int n;
- for (n = 0; n < 6; n++)
- s[n] = (call[n] >> 1) & 0x7F;
+ for (n = 0; n < 6; n++) {
+ c = call[n];
+ s[n] = (c >> 1) & 0x7F;
+ }
s[6] = '\0';
if (strspn(s, "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ ") == 6)