From 93e0d8c67a1123d0b4eefcc53d00ba892142fd49 Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Sat, 6 Mar 2010 00:57:56 -0500 Subject: Abstracted an sha1sum() function --- src/xact.cc | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'src/xact.cc') diff --git a/src/xact.cc b/src/xact.cc index 5dbf8c70..f78ea301 100644 --- a/src/xact.cc +++ b/src/xact.cc @@ -454,12 +454,7 @@ string xact_t::idstring() const string xact_t::id() const { - SHA1 sha; - sha.Reset(); - sha << idstring().c_str(); - uint_least32_t message_digest[5]; - sha.Result(message_digest); - return to_hex(message_digest, 5); + return sha1sum(idstring()); } namespace { -- cgit v1.2.3