diff options
Diffstat (limited to 'src/utility.h')
-rw-r--r-- | src/utility.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/utility.h b/src/utility.h index 8839887f7..cc69099b4 100644 --- a/src/utility.h +++ b/src/utility.h @@ -1474,8 +1474,11 @@ void mysrand(unsigned seed); inline int myrand_range(int min, int max) { - if(min >= max) + if(min > max) + { + assert(0); return max; + } return (myrand()%(max-min+1))+min; } |