diff --git a/CHANGELOG.md b/CHANGELOG.md index b7720543..9173d08e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,12 @@ Versioning](https://semver.org/spec/v2.0.0.html). ### yabridgectl +- Fixed regression where the configuration file failed to parse after running + `yabridgectl sync` caused by + [alexcrichton/toml-rs#256](https://github.com/alexcrichton/toml-rs/issues/256) + 4.0. If you have already run `yabridgectl sync` under yabridge 1.4.0, then + you'll have to manually remove the `[last_known_config]` section from + `~/.config/yabridgectl/config.toml`. - Fixed issue with overwriting broken symlinks during `yabridgectl sync`. ## [1.4.0] - 2020-07-26 diff --git a/tools/yabridgectl/src/config.rs b/tools/yabridgectl/src/config.rs index 8f56ed10..bb8829e3 100644 --- a/tools/yabridgectl/src/config.rs +++ b/tools/yabridgectl/src/config.rs @@ -108,7 +108,13 @@ pub struct KnownConfig { /// The results from running the contents of `yabridge-host.exe.so` through /// [`DefaultHasher`](std::collections::hash_map::DefaultHasher). Hash collisions aren't really /// an issue here since we mostly care about the version of Wine. - pub yabridge_host_hash: u64, + /// + /// This should have been stored as a `u64`, but the TOML library parses all integers as signed + /// so even though it will be able to serialize all values correctly some values will fail to + /// parse: + /// + /// https://github.com/alexcrichton/toml-rs/issues/256 + pub yabridge_host_hash: i64, } impl Config { diff --git a/tools/yabridgectl/src/utils.rs b/tools/yabridgectl/src/utils.rs index 5e02b3ac..12880112 100644 --- a/tools/yabridgectl/src/utils.rs +++ b/tools/yabridgectl/src/utils.rs @@ -183,7 +183,7 @@ pub fn verify_wine_setup(config: &mut Config) -> Result<()> { yabridge_host_exe_so_path.display() ) })?); - let yabridge_host_hash = hasher.finish(); + let yabridge_host_hash = hasher.finish() as i64; // Since these checks can take over a second if wineserver isn't already running we'll only // perform them when something has changed