LRU simulator: fix new entry creation decr time.

This commit is contained in:
antirez 2016-07-14 15:55:17 +02:00
parent f50dc38bc2
commit fc92c667f7

View File

@ -137,7 +137,7 @@ int main(void) {
if (new_entry_time <= now) {
idx = 10+(rand()%10);
entries[idx].counter = COUNTER_INIT_VAL;
entries[idx].decrtime = to_16bit_minutes(start);
entries[idx].decrtime = to_16bit_minutes(time(NULL));
entries[idx].hits = 0;
entries[idx].ctime = time(NULL);
new_entry_time = now+10;