summaryrefslogtreecommitdiff
path: root/MdePkg/Library/BaseMemoryLibSse2/SetMem32Wrapper.c
diff options
context:
space:
mode:
Diffstat (limited to 'MdePkg/Library/BaseMemoryLibSse2/SetMem32Wrapper.c')
-rw-r--r--MdePkg/Library/BaseMemoryLibSse2/SetMem32Wrapper.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/MdePkg/Library/BaseMemoryLibSse2/SetMem32Wrapper.c b/MdePkg/Library/BaseMemoryLibSse2/SetMem32Wrapper.c
index 620b69aef4..1ae7acb013 100644
--- a/MdePkg/Library/BaseMemoryLibSse2/SetMem32Wrapper.c
+++ b/MdePkg/Library/BaseMemoryLibSse2/SetMem32Wrapper.c
@@ -52,10 +52,10 @@ SetMem32 (
IN UINT32 Value
)
{
- ASSERT (Buffer != NULL);
+ ASSERT (!(Buffer == NULL && Length > 0));
ASSERT (Length <= MAX_ADDRESS - (UINTN)Buffer + 1);
- ASSERT ((((UINTN)Buffer) & (sizeof (Value) - 1)) != 0);
- ASSERT ((Length & (sizeof (Value) - 1)) != 0);
+ ASSERT ((((UINTN)Buffer) & (sizeof (Value) - 1)) == 0);
+ ASSERT ((Length & (sizeof (Value) - 1)) == 0);
if ((Length /= sizeof (Value)) == 0) {
return Buffer;