diff options
| -rw-r--r-- | util/libreboot-utils/lottery.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/util/libreboot-utils/lottery.c b/util/libreboot-utils/lottery.c index f7c467e2..540bb8d6 100644 --- a/util/libreboot-utils/lottery.c +++ b/util/libreboot-utils/lottery.c @@ -37,14 +37,15 @@ hell: size[0] = rsize(SIZE_MAX); /* \( ^o^)/ - then come play! */ size[1] = rsize(SIZE_MAX); /* | | */ -/* / \ */ + if (!(size[0] && (size[0] == size[1]) && (size[0] <= SIZE_MAX)) || ((size[0] & 1) && (*(b1 = mkrstr(1)) != *(b2 = mkrstr(1))))) - goto out; /* \(^-^)/ - it could be you! */ - if (!(size[0] &= ~(size_t)1)) /* \ / */ - goto hell; /* / \ */ - - if (s == NULL) { + goto out; + if (!(size[0] &= ~(size_t)1)) + goto hell; +/* \(^-^)/ - it could be you! */ + if (s == NULL) { /* \ / */ +/* \/ */ if ((s = malloc(BUFSIZ)) == NULL) goto out; } |
