aboutsummaryrefslogtreecommitdiffstats
path: root/btrfs-crc.c
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.cz>2013-07-09 18:38:29 +0200
committerDavid Sterba <dsterba@suse.cz>2013-08-09 14:32:34 +0200
commit309e50c7634f0603dab866ad699e7981e9fca004 (patch)
treecaff8de092c97c6318a4ea3b077f4fd3f73a8444 /btrfs-crc.c
parent89fde183ebbc87a930592b0f6f1e3301224f6682 (diff)
downloadbtrfs-progs-309e50c7634f0603dab866ad699e7981e9fca004.tar.gz
btrfs-progs-309e50c7634f0603dab866ad699e7981e9fca004.tar.xz
btrfs-progs-309e50c7634f0603dab866ad699e7981e9fca004.zip
btrfs-progs: Fix getopt on arm/ppc platforms
(same as commit bb0eabc383e9a3fde7cdb02591ca88243f3e31fb) There, 'char' is unsigned, so once assigned '-1' from getopt, it gets the value 255. Then, it compared to '-1' gives false. Signed-off-by: David Sterba <dsterba@suse.cz> Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Diffstat (limited to 'btrfs-crc.c')
-rw-r--r--btrfs-crc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/btrfs-crc.c b/btrfs-crc.c
index e4cda43..1990534 100644
--- a/btrfs-crc.c
+++ b/btrfs-crc.c
@@ -34,7 +34,7 @@ void usage(void)
int main(int argc, char **argv)
{
- char c;
+ int c;
unsigned long checksum = 0;
char *str;
char *buf;