From e96de4bc2817470d18256e4df65406ec7cd8e48b Mon Sep 17 00:00:00 2001 From: Edison Su Date: Thu, 24 May 2012 15:07:17 -0700 Subject: [PATCH] CS-14826, CS-14996: fix the md5 checksum --- core/src/com/cloud/storage/template/DownloadManagerImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/com/cloud/storage/template/DownloadManagerImpl.java b/core/src/com/cloud/storage/template/DownloadManagerImpl.java index 4f01842cbab..b9fc038dca6 100755 --- a/core/src/com/cloud/storage/template/DownloadManagerImpl.java +++ b/core/src/com/cloud/storage/template/DownloadManagerImpl.java @@ -293,7 +293,7 @@ public class DownloadManagerImpl implements DownloadManager { } byte[] md5sum = digest.digest(); BigInteger bigInt = new BigInteger(1, md5sum); - checksum = bigInt.toString(16); + checksum = String.format("%032x",bigInt.toString(16)); return checksum; }catch(IOException e) { return null;