Skip to content

Commit

Permalink
change magic number for fingerprint files
Browse files Browse the repository at this point in the history
  • Loading branch information
damiendoligez committed Nov 12, 2024
1 parent b12dfff commit aedbabc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/backend/fpfile.ml
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,8 @@ open V13

let fptbl = ref (Hashtbl.create 500 : V13.tbl)

let old_magic_number = 20101013
let magic_number = 20210223
let old_magic_numbers = [20101013; 20210223]
let magic_number = 20241112

let write_fp_table oc =
output_value oc magic_number;
Expand Down Expand Up @@ -568,7 +568,7 @@ let load_fingerprints_aux file =
if Sys.file_exists file then begin
let ic = open_in_bin file in
let magic = Marshal.from_channel ic in
if magic = old_magic_number then
if List.mem magic old_magic_numbers then
raise(FpFileOlderMagicNumber);
if magic <> magic_number then raise(FpFileCorrupted);
let v = Marshal.from_channel ic in
Expand Down

0 comments on commit aedbabc

Please sign in to comment.