diff options
author | vanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524> | 2006-05-24 08:44:35 +0000 |
---|---|---|
committer | vanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524> | 2006-05-24 08:44:35 +0000 |
commit | 1dc408f8910b1ddca89cff2ebdbf8e712df583d8 (patch) | |
tree | d15d8f824df45a60f7fc52741ee248a099effb01 /MdePkg/Library/BaseLib/Unaligned.c | |
parent | a916cff8a0113a532ba9a3091f008fdfbac55528 (diff) | |
download | edk2-platforms-1dc408f8910b1ddca89cff2ebdbf8e712df583d8.tar.xz |
added ASSERT()
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@260 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdePkg/Library/BaseLib/Unaligned.c')
-rw-r--r-- | MdePkg/Library/BaseLib/Unaligned.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/MdePkg/Library/BaseLib/Unaligned.c b/MdePkg/Library/BaseLib/Unaligned.c index 9d0521e595..a54a99e7e6 100644 --- a/MdePkg/Library/BaseLib/Unaligned.c +++ b/MdePkg/Library/BaseLib/Unaligned.c @@ -33,6 +33,8 @@ ReadUnaligned16 ( IN CONST UINT16 *Buffer
)
{
+ ASSERT (Buffer != NULL);
+
return *Buffer;
}
@@ -58,6 +60,8 @@ WriteUnaligned16 ( IN UINT16 Value
)
{
+ ASSERT (Buffer != NULL);
+
return *Buffer = Value;
}
@@ -80,6 +84,8 @@ ReadUnaligned24 ( IN CONST UINT32 *Buffer
)
{
+ ASSERT (Buffer != NULL);
+
return *Buffer & 0xffffff;
}
@@ -105,6 +111,8 @@ WriteUnaligned24 ( IN UINT32 Value
)
{
+ ASSERT (Buffer != NULL);
+
return *Buffer = BitFieldWrite32 (*Buffer, 0, 23, Value);
}
@@ -127,6 +135,8 @@ ReadUnaligned32 ( IN CONST UINT32 *Buffer
)
{
+ ASSERT (Buffer != NULL);
+
return *Buffer;
}
@@ -152,6 +162,8 @@ WriteUnaligned32 ( IN UINT32 Value
)
{
+ ASSERT (Buffer != NULL);
+
return *Buffer = Value;
}
@@ -174,6 +186,8 @@ ReadUnaligned64 ( IN CONST UINT64 *Buffer
)
{
+ ASSERT (Buffer != NULL);
+
return *Buffer;
}
@@ -199,5 +213,7 @@ WriteUnaligned64 ( IN UINT64 Value
)
{
+ ASSERT (Buffer != NULL);
+
return *Buffer = Value;
}
|