Merge pull request #3784 from badboy/dont-divide-by-zero

Don't divide by zero
This commit is contained in:
Salvatore Sanfilippo 2017-01-27 16:26:24 +01:00 committed by GitHub
commit 713fe0b7d7

View File

@ -951,7 +951,7 @@ sds getMemoryDoctorReport(void) {
}
/* Slaves using more than 10 MB each? */
if (mh->clients_slaves / numslaves > (1024*1024*10)) {
if (numslaves > 0 && mh->clients_slaves / numslaves > (1024*1024*10)) {
big_slave_buf = 1;
num_reports++;
}