Skip to content

Commit

Permalink
cachedb_local: fix expiration of keys received through cluster sync
Browse files Browse the repository at this point in the history
Credits to Kingsley Tart from CallTracks for reporting.

(cherry picked from commit d0c4fc4)
  • Loading branch information
rvlad-patrascu committed Oct 21, 2022
1 parent ea206a4 commit 287094b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modules/cachedb_local/cachedb_local_replication.c
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,8 @@ int receive_sync_request(int node_id)
bin_push_str(sync_packet, &col->col_name);
bin_push_str(sync_packet, &data->attr);
bin_push_str(sync_packet, &data->value);
bin_push_int(sync_packet, data->expires);
bin_push_int(sync_packet, data->expires ?
data->expires - get_ticks() : 0);
}
data = data->next;
}
Expand Down

0 comments on commit 287094b

Please sign in to comment.