Skip to content

Commit

Permalink
Fix PkgCacheInspector.jl for relocatable precompile files
Browse files Browse the repository at this point in the history
parse_cache_header now takes a second string argument after an IO

JuliaLang/julia#49866
  • Loading branch information
mkitti committed Nov 21, 2023
1 parent 6552676 commit dfd4dd5
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/PkgCacheInspector.jl
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,12 @@ function info_cachefile(pkg::PkgId, path::String)
try
# isvalid_cache_header returns checksum id or zero
isvalid_cache_header(io) == 0 && return ArgumentError("Invalid header in cache file $path.")
depmodnames = parse_cache_header(io)[3]
# https://github.com/JuliaLang/julia/pull/49866
if VERSION >= v"1.11.0-DEV.946" # lower bound could be lower
depmodnames = parse_cache_header(io, path)[3]
else
depmodnames = parse_cache_header(io)[3]
end
isvalid_file_crc(io) || return ArgumentError("Invalid checksum in cache file $path.")
finally
close(io)
Expand Down

0 comments on commit dfd4dd5

Please sign in to comment.