diff options
author | Jim Meyering <meyering@fb.com> | 2013-11-18 17:35:01 -0800 |
---|---|---|
committer | Jim Meyering <meyering@fb.com> | 2013-11-22 08:15:12 -0800 |
commit | 831b84c59ef413c57a36b67344467d66a8a2ba70 (patch) | |
tree | 6f3933ca9f3cfaf9081c8d5f93fdf552e26b1c8e /build-aux/gendocs.sh | |
parent | 8b40415718be86c3a37388ba35804be74b8f376e (diff) | |
download | gnulib-831b84c59ef413c57a36b67344467d66a8a2ba70.tar.gz |
quotearg: don't attempt to store 1 << 31 into an "int"
* lib/quotearg.c (quotearg_buffer_restyled): Building coreutils with
gcc's new -fsanitize=undefined and running its tests triggered some
new test failures due to undefined behavior, all with this diagnostic:
lib/quotearg.c:629:62: runtime error: left shift of 1 by 31 places \
cannot be represented in type int
Rather than shifting "1" left to form a mask, shift the bits right and
simply use "1" as the mask.
Co-authored-by: Paul Eggert <eggert@cs.ucla.edu>
Diffstat (limited to 'build-aux/gendocs.sh')
0 files changed, 0 insertions, 0 deletions