@@ -61,9 +61,17 @@ findidx (const int32_t *table,
already. */
size_t cnt;
+ /* In GCC 5.3 compiling for i486 the compiler complains that
+ seq2.back_us, which becomes usrc, might be used
+ uninitialized. This can't be true because we pass a length
+ of -1 for len at the same time which means that this loop
+ never executes. */
+ DIAG_PUSH_NEEDS_COMMENT;
+ DIAG_IGNORE_NEEDS_COMMENT (5.3, "-Wmaybe-uninitialized");
for (cnt = 0; cnt < nhere && cnt < len; ++cnt)
if (cp[cnt] != usrc[cnt])
break;
+ DIAG_POP_NEEDS_COMMENT;
if (cnt == nhere)
{
@@ -59,9 +59,17 @@ findidx (const int32_t *table,
already. */
size_t cnt;
+ /* In GCC 5.3 compiling for i486 the compiler complains that
+ seq2.back_us, which becomes usrc, might be used
+ uninitialized. This can't be true because we pass a length
+ of -1 for len at the same time which means that this loop
+ never executes. */
+ DIAG_PUSH_NEEDS_COMMENT;
+ DIAG_IGNORE_NEEDS_COMMENT (5.3, "-Wmaybe-uninitialized");
for (cnt = 0; cnt < nhere && cnt < len; ++cnt)
if (cp[cnt] != usrc[cnt])
break;
+ DIAG_POP_NEEDS_COMMENT;
if (cnt == nhere)
{
@@ -24,6 +24,7 @@
#include <stdint.h>
#include <string.h>
#include <sys/param.h>
+#include <libc-internal.h>
#ifndef STRING_TYPE
# define STRING_TYPE char
@@ -170,7 +171,19 @@ get_next_seq (coll_seq *seq, int nrules, const unsigned char *rulesets,
}
}
+ /* In GCC 5.3 compiling for i486 the compiler complains that idx,
+ taken from seq->idx (seq1 or seq2 from STRCOLL) may be used
+ uninitialized. In general this can't possibly be true since
+ seq1.idx and seq2.idx are initialized to zero in the outer
+ function. Only one case where seq->idx is restored from
+ seq->save_idx might result in an uninitialized idx value, but
+ it is guarded by a sequence of checks against backw_stop which
+ ensures that seq->save_idx was saved to first and contains a
+ valid value. */
+ DIAG_PUSH_NEEDS_COMMENT;
+ DIAG_IGNORE_NEEDS_COMMENT (5.3, "-Wmaybe-uninitialized");
len = weights[idx++];
+ DIAG_POP_NEEDS_COMMENT;
/* Skip over indices of previous levels. */
for (int i = 0; i < pass; i++)
{