gravatar
deba@inf.elte.hu
deba@inf.elte.hu
Array range check warning workaround in random.h The g++-4.2.1 preferred by OpenSUSE has a bug with array range cheking
0 1 0
default
1 file changed with 1 insertions and 1 deletions:
↑ Collapse diff ↑
Ignore white space 12 line context
... ...
@@ -251,13 +251,13 @@
251 251
        num = shift - 1;
252 252
        while (num--) {
253 253
          curr[0] = (((curr[0] & hiMask) | (curr[-1] & loMask)) >> 1) ^
254 254
            curr[length - shift] ^ mask[curr[-1] & 1ul];
255 255
          --curr;
256 256
        }
257
        curr[0] = (((curr[0] & hiMask) | (curr[length - 1] & loMask)) >> 1) ^
257
        state[0] = (((state[0] & hiMask) | (curr[length - 1] & loMask)) >> 1) ^
258 258
          curr[length - shift] ^ mask[curr[length - 1] & 1ul];
259 259

	
260 260
      }
261 261

	
262 262
  
263 263
      Word *current;
0 comments (0 inline)