summaryrefslogtreecommitdiff
path: root/lib/quotearg.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/quotearg.c')
-rw-r--r--lib/quotearg.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/quotearg.c b/lib/quotearg.c
index 64fa67635..8c95b7ae5 100644
--- a/lib/quotearg.c
+++ b/lib/quotearg.c
@@ -84,7 +84,7 @@ struct quoting_options
/* Quote the characters indicated by this bit vector even if the
quoting style would not normally require them to be quoted. */
- int quote_these_too[(UCHAR_MAX / INT_BITS) + 1];
+ unsigned int quote_these_too[(UCHAR_MAX / INT_BITS) + 1];
};
/* Names of quoting styles. */
@@ -152,7 +152,8 @@ int
set_char_quoting (struct quoting_options *o, char c, int i)
{
unsigned char uc = c;
- int *p = (o ? o : &default_quoting_options)->quote_these_too + uc / INT_BITS;
+ unsigned int *p =
+ (o ? o : &default_quoting_options)->quote_these_too + uc / INT_BITS;
int shift = uc % INT_BITS;
int r = (*p >> shift) & 1;
*p ^= ((i & 1) ^ r) << shift;