diff options
Diffstat (limited to 'MdePkg/Library/BaseMemoryLib/CompareMemWrapper.c')
-rw-r--r-- | MdePkg/Library/BaseMemoryLib/CompareMemWrapper.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/MdePkg/Library/BaseMemoryLib/CompareMemWrapper.c b/MdePkg/Library/BaseMemoryLib/CompareMemWrapper.c index 031b7fcec6..61b01096b2 100644 --- a/MdePkg/Library/BaseMemoryLib/CompareMemWrapper.c +++ b/MdePkg/Library/BaseMemoryLib/CompareMemWrapper.c @@ -58,7 +58,7 @@ CompareMem ( IN UINTN Length
)
{
- if (0 == Length) {
+ if (Length == 0 || DestinationBuffer == SourceBuffer) {
return 0;
}
ASSERT (DestinationBuffer != NULL);
|