From af5ea1ac0fb11dd32844320abf6805a680a79987 Mon Sep 17 00:00:00 2001 From: Drew Short Date: Sun, 14 May 2017 15:22:21 -0500 Subject: [PATCH] Updating dependencies. Incrementing patch version. --- Cargo.toml | 18 +++++++++--------- src/cache.rs | 3 ++- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 0c74e27..2c4f162 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "pihash" -version = "0.3.4" +version = "0.3.5" authors = ["Drew Short "] description = "A simple library for generating perceptual hashes for images and comparing images based on their perceptual hashes." repository = "https://github.com/warricksothr/Perceptual-Image-Hashing/" @@ -20,11 +20,11 @@ default = [] bench = [] [dependencies] -libc = "0.2.10" -rustc-serialize = "0.3.19" -dft = "0.4.3" -image = "0.9.0" -num = "0.1.32" -docopt = "0.6.80" -flate2 = "0.2.13" -sha1 = "0.1.1" \ No newline at end of file +libc = "0.2.20" +rustc-serialize = "0.3.22" +dft = "0.5.4" +image = "0.13.0" +num = "0.1.36" +docopt = "0.7.0" +flate2 = "0.2.19" +sha1 = "0.2.0" diff --git a/src/cache.rs b/src/cache.rs index cb93a15..9f5c2a8 100644 --- a/src/cache.rs +++ b/src/cache.rs @@ -139,8 +139,9 @@ impl<'a> Cache<'a> { try!(source.read_to_end(&mut buf)); let mut sha1 = Sha1::new(); sha1.update(&buf); + let digest = sha1.digest(); // Return the hex result of the hash - Ok(sha1.hexdigest()) + Ok(format!("{}", digest)) } /**