diff options
author | gdong1 <gdong1@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-07-26 05:17:35 +0000 |
---|---|---|
committer | gdong1 <gdong1@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-07-26 05:17:35 +0000 |
commit | f5af77a80ff54f3c37cfb16ff5ede38a75008ea1 (patch) | |
tree | 2fcff513f06d330e66286b2c5f8ae50b4cedc5ad /SecurityPkg/Tcg/TcgDxe | |
parent | 5a5003323610f215591bd3c0bd1a426583e70fc7 (diff) | |
download | edk2-f5af77a80ff54f3c37cfb16ff5ede38a75008ea1.tar.gz edk2-f5af77a80ff54f3c37cfb16ff5ede38a75008ea1.tar.bz2 edk2-f5af77a80ff54f3c37cfb16ff5ede38a75008ea1.zip |
Fix a failure in TCG HashAll interface.
signed-off by Tao Hengyan <hengyan.tao@intel.com>
reviewed by Dong Guo <guo.dong@intel.com>
reviewed by Long Qin <qin.long@intel.com>
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13556 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'SecurityPkg/Tcg/TcgDxe')
-rw-r--r-- | SecurityPkg/Tcg/TcgDxe/TcgDxe.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/SecurityPkg/Tcg/TcgDxe/TcgDxe.c b/SecurityPkg/Tcg/TcgDxe/TcgDxe.c index 5b8f45d83f..4b5380ba87 100644 --- a/SecurityPkg/Tcg/TcgDxe/TcgDxe.c +++ b/SecurityPkg/Tcg/TcgDxe/TcgDxe.c @@ -262,6 +262,10 @@ TcgDxeHashAll ( }
*HashedDataLen = sizeof (TPM_DIGEST);
+ if (*HashedDataResult == NULL) {
+ *HashedDataResult = AllocatePool ((UINTN) *HashedDataLen);
+ }
+
return TpmCommHashAll (
HashData,
(UINTN) HashDataLen,
|