forked from Proxmox/proxmox
apt: updates for changed api (digest as array)
Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
This commit is contained in:
parent
bcca060a93
commit
79f2b89d29
@ -200,7 +200,7 @@ impl APTRepositoryFileImpl for APTRepositoryFile {
|
||||
}
|
||||
|
||||
self.repositories = repos;
|
||||
self.digest = Some(digest);
|
||||
self.digest = Some(*digest);
|
||||
|
||||
Ok(())
|
||||
}
|
||||
@ -221,7 +221,7 @@ impl APTRepositoryFileImpl for APTRepositoryFile {
|
||||
}
|
||||
|
||||
let (_, current_digest) = self.read_with_digest()?;
|
||||
if digest != ¤t_digest {
|
||||
if *digest != *current_digest {
|
||||
return Err(self.err(format_err!("digest mismatch")));
|
||||
}
|
||||
}
|
||||
|
@ -137,7 +137,7 @@ fn test_digest() -> Result<(), Error> {
|
||||
|
||||
// expect a different digest, because the repo was modified
|
||||
let (_, new_digest) = file.read_with_digest()?;
|
||||
assert_ne!(old_digest, new_digest);
|
||||
assert_ne!(old_digest, *new_digest);
|
||||
|
||||
assert!(file.write().is_err());
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user