diff options
author | John Keeping | 2015-03-08 16:32:17 +0000 |
---|---|---|
committer | Jason A. Donenfeld | 2015-03-09 17:38:46 +0100 |
commit | 12d3d4c3edfcf177c56ca97e5a4b0c8301ca46aa (patch) | |
tree | bae9ba5a16e0cbd0aa698d8635927b8b122a476c | |
parent | Avoid non-ANSI function declarations (diff) | |
download | cgit-12d3d4c3edfcf177c56ca97e5a4b0c8301ca46aa.tar.gz cgit-12d3d4c3edfcf177c56ca97e5a4b0c8301ca46aa.zip |
Avoid signed bitfields
Bitfields are only defined for unsigned types. Detected by sparse. Signed-off-by: John Keeping <john@keeping.me.uk>
-rw-r--r-- | ui-blob.c | 4 | ||||
-rw-r--r-- | ui-diff.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/ui-blob.c b/ui-blob.c index a025bca..388a017 100644 --- a/ui-blob.c +++ b/ui-blob.c | |||
@@ -14,8 +14,8 @@ | |||
14 | struct walk_tree_context { | 14 | struct walk_tree_context { |
15 | const char *match_path; | 15 | const char *match_path; |
16 | unsigned char *matched_sha1; | 16 | unsigned char *matched_sha1; |
17 | int found_path:1; | 17 | unsigned int found_path:1; |
18 | int file_only:1; | 18 | unsigned int file_only:1; |
19 | }; | 19 | }; |
20 | 20 | ||
21 | static int walk_tree(const unsigned char *sha1, struct strbuf *base, | 21 | static int walk_tree(const unsigned char *sha1, struct strbuf *base, |
diff --git a/ui-diff.c b/ui-diff.c index 8eff178..1cf2ce0 100644 --- a/ui-diff.c +++ b/ui-diff.c | |||
@@ -31,7 +31,7 @@ static struct fileinfo { | |||
31 | unsigned int removed; | 31 | unsigned int removed; |
32 | unsigned long old_size; | 32 | unsigned long old_size; |
33 | unsigned long new_size; | 33 | unsigned long new_size; |
34 | int binary:1; | 34 | unsigned int binary:1; |
35 | } *items; | 35 | } *items; |
36 | 36 | ||
37 | static int use_ssdiff = 0; | 37 | static int use_ssdiff = 0; |