Sync with PE/COFF Extra Action library class comments and add ASSERT() conditions if ImageContext is NULL.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8274 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@@ -68,13 +68,12 @@ DxeUnixPeCoffLibExtraActionConstructor (
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Applies additional actions to relocate fixups to a PE/COFF image.
|
Performs additional actions after a PE/COFF image has been loaded and relocated.
|
||||||
|
|
||||||
Generally this function is called after sucessfully Applying relocation fixups
|
If ImageContext is NULL, then ASSERT().
|
||||||
to a PE/COFF image for some specicial purpose.
|
|
||||||
|
|
||||||
@param ImageContext Pointer to the image context structure that describes the PE/COFF
|
@param ImageContext Pointer to the image context structure that describes the
|
||||||
image that is being relocated.
|
PE/COFF image that has already been loaded and relocated.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
VOID
|
VOID
|
||||||
@@ -86,6 +85,8 @@ PeCoffLoaderRelocateImageExtraAction (
|
|||||||
VOID * Handle;
|
VOID * Handle;
|
||||||
VOID * Entry;
|
VOID * Entry;
|
||||||
|
|
||||||
|
ASSERT (ImageContext != NULL);
|
||||||
|
|
||||||
Handle = NULL;
|
Handle = NULL;
|
||||||
Entry = NULL;
|
Entry = NULL;
|
||||||
|
|
||||||
@@ -112,15 +113,13 @@ PeCoffLoaderRelocateImageExtraAction (
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Unloads a loaded PE/COFF image from memory and releases its taken resource.
|
Performs additional actions just before a PE/COFF image is unloaded. Any resources
|
||||||
|
that were allocated by PeCoffLoaderRelocateImageExtraAction() must be freed.
|
||||||
Releases any environment specific resources that were allocated when the image
|
|
||||||
specified by ImageContext was loaded using PeCoffLoaderLoadImage().
|
|
||||||
|
|
||||||
If ImageContext is NULL, then ASSERT().
|
If ImageContext is NULL, then ASSERT().
|
||||||
|
|
||||||
@param ImageContext Pointer to the image context structure that describes the PE/COFF
|
@param ImageContext Pointer to the image context structure that describes the
|
||||||
image to be unloaded.
|
PE/COFF image that is being unloaded.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
VOID
|
VOID
|
||||||
@@ -129,4 +128,5 @@ PeCoffLoaderUnloadImageExtraAction (
|
|||||||
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
|
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
ASSERT (ImageContext != NULL);
|
||||||
}
|
}
|
||||||
|
@@ -70,13 +70,12 @@ UnixPeCoffGetUnixThunkStucture (
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Applies additional actions to relocate fixups to a PE/COFF image.
|
Performs additional actions after a PE/COFF image has been loaded and relocated.
|
||||||
|
|
||||||
Generally this function is called after sucessfully Applying relocation fixups
|
If ImageContext is NULL, then ASSERT().
|
||||||
to a PE/COFF image for some specicial purpose.
|
|
||||||
|
|
||||||
@param ImageContext Pointer to the image context structure that describes the PE/COFF
|
@param ImageContext Pointer to the image context structure that describes the
|
||||||
image that is being relocated.
|
PE/COFF image that has already been loaded and relocated.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
VOID
|
VOID
|
||||||
@@ -88,6 +87,8 @@ PeCoffLoaderRelocateImageExtraAction (
|
|||||||
VOID * Handle;
|
VOID * Handle;
|
||||||
VOID * Entry;
|
VOID * Entry;
|
||||||
|
|
||||||
|
ASSERT (ImageContext != NULL);
|
||||||
|
|
||||||
Handle = NULL;
|
Handle = NULL;
|
||||||
Entry = NULL;
|
Entry = NULL;
|
||||||
|
|
||||||
@@ -117,15 +118,13 @@ PeCoffLoaderRelocateImageExtraAction (
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Unloads a loaded PE/COFF image from memory and releases its taken resource.
|
Performs additional actions just before a PE/COFF image is unloaded. Any resources
|
||||||
|
that were allocated by PeCoffLoaderRelocateImageExtraAction() must be freed.
|
||||||
Releases any environment specific resources that were allocated when the image
|
|
||||||
specified by ImageContext was loaded using PeCoffLoaderLoadImage().
|
|
||||||
|
|
||||||
If ImageContext is NULL, then ASSERT().
|
If ImageContext is NULL, then ASSERT().
|
||||||
|
|
||||||
@param ImageContext Pointer to the image context structure that describes the PE/COFF
|
@param ImageContext Pointer to the image context structure that describes the
|
||||||
image to be unloaded.
|
PE/COFF image that is being unloaded.
|
||||||
|
|
||||||
**/
|
**/
|
||||||
VOID
|
VOID
|
||||||
@@ -134,4 +133,5 @@ PeCoffLoaderUnloadImageExtraAction (
|
|||||||
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
|
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
ASSERT (ImageContext != NULL);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user