diff options
author | qwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-02-04 03:18:43 +0000 |
---|---|---|
committer | qwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-02-04 03:18:43 +0000 |
commit | 38c0d70af863b85ffbd0e4c8e6a63c2167c31145 (patch) | |
tree | e18076c784dff3761f6418a6be226b067f5408d9 | |
parent | 39d262c4ce5924e80e169a2558a81a6e349249cb (diff) | |
download | edk2-38c0d70af863b85ffbd0e4c8e6a63c2167c31145.tar.gz edk2-38c0d70af863b85ffbd0e4c8e6a63c2167c31145.tar.bz2 edk2-38c0d70af863b85ffbd0e4c8e6a63c2167c31145.zip |
Check the handle for font package before remove it.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@4667 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r-- | MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c index ff4b0c209a..11d1c764a8 100644 --- a/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c +++ b/MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c @@ -618,12 +618,10 @@ GraphicsConsoleControllerDriverStop ( //
// Remove the font pack
//
-#if 1
- HiiLibRemovePackages (Private->HiiHandle);
- mFirstAccessFlag = TRUE;
-#else
- mHii->RemovePack (mHii, Private->HiiHandle);
-#endif
+ if (Private->HiiHandle != NULL) {
+ HiiLibRemovePackages (Private->HiiHandle);
+ mFirstAccessFlag = TRUE;
+ }
//
// Free our instance data
|