Index: /trunk/src/VBox/Runtime/common/checksum/RTSha1Digest.cpp
===================================================================
--- /trunk/src/VBox/Runtime/common/checksum/RTSha1Digest.cpp	(revision 29777)
+++ /trunk/src/VBox/Runtime/common/checksum/RTSha1Digest.cpp	(revision 29778)
@@ -36,4 +36,5 @@
 #include <iprt/stream.h>
 #include <iprt/string.h>
+#include <iprt/mem.h>
 
 #include <openssl/sha.h>
@@ -89,11 +90,8 @@
         return VERR_INTERNAL_ERROR;
 
-    int cch = RTStrAPrintf(ppszDigest, "%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x",
-                           auchDig[0] , auchDig[1] , auchDig[2] , auchDig[3] , auchDig[4],
-                           auchDig[5] , auchDig[6] , auchDig[7] , auchDig[8] , auchDig[9],
-                           auchDig[10], auchDig[11], auchDig[12], auchDig[13], auchDig[14],
-                           auchDig[15], auchDig[16], auchDig[17], auchDig[18], auchDig[19]);
-    if (RT_UNLIKELY(cch == -1))
-        rc = VERR_INTERNAL_ERROR;
+    *ppszDigest = (char*)RTMemAlloc(41);
+    rc = RTSha1ToString(auchDig, *ppszDigest, 41);
+    if (RT_FAILURE(rc))
+        RTStrFree(*ppszDigest);
 
     return rc;
