diff options
author | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-12-03 15:38:24 +0000 |
---|---|---|
committer | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-12-03 15:38:24 +0000 |
commit | b52f6a1ad8029588a8b1e3b8cfd4855ee6d5a727 (patch) | |
tree | f5ebc2406840670f8dfb79b7c84e2876053d63fa /MdePkg | |
parent | 53cf48e083930e279cbd8e12fdd923b7cbd65a9a (diff) | |
download | edk2-platforms-b52f6a1ad8029588a8b1e3b8cfd4855ee6d5a727.tar.xz |
Add CONST modifier for "Buffer" parameter in LibPcdSetPtr()
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6823 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdePkg')
-rw-r--r-- | MdePkg/Include/Library/PcdLib.h | 2 | ||||
-rw-r--r-- | MdePkg/Library/BasePcdLibNull/PcdLib.c | 2 | ||||
-rw-r--r-- | MdePkg/Library/DxePcdLib/DxePcdLib.c | 6 | ||||
-rw-r--r-- | MdePkg/Library/PeiPcdLib/PeiPcdLib.c | 6 |
4 files changed, 8 insertions, 8 deletions
diff --git a/MdePkg/Include/Library/PcdLib.h b/MdePkg/Include/Library/PcdLib.h index 4e2399a565..71034716c8 100644 --- a/MdePkg/Include/Library/PcdLib.h +++ b/MdePkg/Include/Library/PcdLib.h @@ -1171,7 +1171,7 @@ EFIAPI LibPcdSetPtr (
IN UINTN TokenNumber,
IN OUT UINTN *SizeOfBuffer,
- IN VOID *Buffer
+ IN CONST VOID *Buffer
);
diff --git a/MdePkg/Library/BasePcdLibNull/PcdLib.c b/MdePkg/Library/BasePcdLibNull/PcdLib.c index 1688034263..20031ee570 100644 --- a/MdePkg/Library/BasePcdLibNull/PcdLib.c +++ b/MdePkg/Library/BasePcdLibNull/PcdLib.c @@ -483,7 +483,7 @@ EFIAPI LibPcdSetPtr (
IN UINTN TokenNumber,
IN OUT UINTN *SizeOfBuffer,
- IN VOID *Buffer
+ IN CONST VOID *Buffer
)
{
ASSERT (FALSE);
diff --git a/MdePkg/Library/DxePcdLib/DxePcdLib.c b/MdePkg/Library/DxePcdLib/DxePcdLib.c index e5d05fbe8c..c313bb7687 100644 --- a/MdePkg/Library/DxePcdLib/DxePcdLib.c +++ b/MdePkg/Library/DxePcdLib/DxePcdLib.c @@ -529,7 +529,7 @@ EFIAPI LibPcdSetPtr (
IN UINTN TokenNumber,
IN OUT UINTN *SizeOfBuffer,
- IN VOID *Buffer
+ IN CONST VOID *Buffer
)
{
EFI_STATUS Status;
@@ -540,13 +540,13 @@ LibPcdSetPtr ( ASSERT (Buffer != NULL);
}
- Status = mPcd->SetPtr (TokenNumber, SizeOfBuffer, Buffer);
+ Status = mPcd->SetPtr (TokenNumber, SizeOfBuffer, (VOID *) Buffer);
if (EFI_ERROR (Status)) {
return NULL;
}
- return Buffer;
+ return (VOID *) Buffer;
}
diff --git a/MdePkg/Library/PeiPcdLib/PeiPcdLib.c b/MdePkg/Library/PeiPcdLib/PeiPcdLib.c index 8f9b7fa64e..ac5bbcf058 100644 --- a/MdePkg/Library/PeiPcdLib/PeiPcdLib.c +++ b/MdePkg/Library/PeiPcdLib/PeiPcdLib.c @@ -524,7 +524,7 @@ EFIAPI LibPcdSetPtr (
IN UINTN TokenNumber,
IN OUT UINTN *SizeOfBuffer,
- IN VOID *Buffer
+ IN CONST VOID *Buffer
)
{
EFI_STATUS Status;
@@ -535,13 +535,13 @@ LibPcdSetPtr ( ASSERT (Buffer != NULL);
}
- Status = (GetPcdPpiPointer ())->SetPtr (TokenNumber, SizeOfBuffer, Buffer);
+ Status = (GetPcdPpiPointer ())->SetPtr (TokenNumber, SizeOfBuffer, (VOID *) Buffer);
if (EFI_ERROR (Status)) {
return NULL;
}
- return Buffer;
+ return (VOID *) Buffer;
}
|