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 e2fd673 commit b65796d
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 @@ -187,7 +187,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 b65796d

Please sign in to comment.