rhg: Fix `rhg status` file content comparison
authorSimon Sapin <simon.sapin@octobus.net>
Tue, 09 Nov 2021 15:43:29 +0100
changeset 48309 594cf89047c8
parent 48308 698b70b9e8ea
child 48310 229f5ee1a08a
rhg: Fix `rhg status` file content comparison This is only used when a file’s metadata make its status ambiguous, which depends on timing of previous command executions. Differential Revision: https://phab.mercurial-scm.org/D11743
rust/rhg/src/commands/status.rs
--- a/rust/rhg/src/commands/status.rs	Wed Oct 27 19:37:46 2021 +0100
+++ b/rust/rhg/src/commands/status.rs	Tue Nov 09 15:43:29 2021 +0100
@@ -312,5 +312,5 @@
 
     let fs_path = hg_path_to_os_string(hg_path).expect("HgPath conversion");
     let fs_contents = repo.working_directory_vfs().read(fs_path)?;
-    return Ok(contents_in_p1 == &*fs_contents);
+    return Ok(contents_in_p1 != &*fs_contents);
 }