Comment 3 for bug 689887

Revision history for this message
Jani Monoses (jani) wrote :

An even smaller testcase

Changing INT_MIN to LONG_LONG_MIN in the conditional fixes the build. (using it this way is arguably a bug in the codebase)

#include <limits.h>

void small(char *dst)

{
        long long y;

        while (1) {
                y = (long long)(*dst) << 8;
                if (y < INT_MIN) {
                        *((int *) dst) = 0;
                } else {
                        *((int *) dst) = 1;
                }
        }
}