]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Nt32Pkg/WinNtBlockIoDxe/DriverDiagnostics.c
Fix the bug that WinNtBlockIo fails to properly allocate a buffer.
[mirror_edk2.git] / Nt32Pkg / WinNtBlockIoDxe / DriverDiagnostics.c
index 69a8f100516b1086a4d9f1bd3ed028fc9c2dba46..18d099bae7eba78e0765ea5057ff1f0f2653ad60 100644 (file)
@@ -1,6 +1,6 @@
 /**@file\r
 \r
-Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>\r
 This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
@@ -179,7 +179,7 @@ WinNtBlockIoDriverDiagnosticsRunDiagnostics (
   if (DiagnosticType != EfiDriverDiagnosticTypeStandard) {\r
     *ErrorType  = &gEfiBlockIoProtocolGuid;\r
     *BufferSize = 0x60;\r
-    Buffer = AllocatePool ((UINTN) (*BufferSize));\r
+    *Buffer = AllocatePool ((UINTN) (*BufferSize));\r
     CopyMem (*Buffer, L"Windows Block I/O Driver Diagnostics Failed\n", *BufferSize);\r
     return EFI_DEVICE_ERROR;\r
   }\r