summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael D Kinney <michael.d.kinney@intel.com>2020-02-10 10:30:19 -0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2020-02-11 23:41:33 +0000
commitf76d50166b69eefbef4bc3895f370a4501c819d1 (patch)
treefdb663355c67d7bb6d157175169219e06ca032db
parent69c135462d9ef28b59a065ad45dc0089d8dacdd0 (diff)
downloadedk2-f76d50166b69eefbef4bc3895f370a4501c819d1.tar.gz
edk2-f76d50166b69eefbef4bc3895f370a4501c819d1.tar.bz2
edk2-f76d50166b69eefbef4bc3895f370a4501c819d1.zip
UnitTestFrameworkPkg/UnitTestLib: Fix XCODE parenthesis issues
https://bugzilla.tianocore.org/show_bug.cgi?id=2512 Remove extra sets of parenthesis that generate warnings on XCODE5 builds. Cc: Sean Brogan <sean.brogan@microsoft.com> Cc: Bret Barkelew <Bret.Barkelew@microsoft.com> Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Sean Brogan <sean.brogan@microsoft.com>
-rw-r--r--UnitTestFrameworkPkg/Library/UnitTestLib/Assert.c6
-rw-r--r--UnitTestFrameworkPkg/Library/UnitTestLib/Log.c2
2 files changed, 4 insertions, 4 deletions
diff --git a/UnitTestFrameworkPkg/Library/UnitTestLib/Assert.c b/UnitTestFrameworkPkg/Library/UnitTestLib/Assert.c
index dd85b84b08..c327ba88f1 100644
--- a/UnitTestFrameworkPkg/Library/UnitTestLib/Assert.c
+++ b/UnitTestFrameworkPkg/Library/UnitTestLib/Assert.c
@@ -247,7 +247,7 @@ UnitTestAssertEqual (
IN CONST CHAR8 *DescriptionB
)
{
- if ((ValueA != ValueB)) {
+ if (ValueA != ValueB) {
UnitTestLogFailure (
FAILURETYPE_ASSERTEQUAL,
"%a::%d Value %a != %a (%d != %d)!\n",
@@ -365,7 +365,7 @@ UnitTestAssertNotEqual (
IN CONST CHAR8 *DescriptionB
)
{
- if ((ValueA == ValueB)) {
+ if (ValueA == ValueB) {
UnitTestLogFailure (
FAILURETYPE_ASSERTNOTEQUAL,
"%a::%d Value %a == %a (%d == %d)!\n",
@@ -420,7 +420,7 @@ UnitTestAssertStatusEqual (
IN CONST CHAR8 *Description
)
{
- if ((Status != Expected)) {
+ if (Status != Expected) {
UnitTestLogFailure (
FAILURETYPE_ASSERTSTATUSEQUAL,
"%a::%d Status '%a' is %r, should be %r!\n",
diff --git a/UnitTestFrameworkPkg/Library/UnitTestLib/Log.c b/UnitTestFrameworkPkg/Library/UnitTestLib/Log.c
index 78df086a28..ac4e229b40 100644
--- a/UnitTestFrameworkPkg/Library/UnitTestLib/Log.c
+++ b/UnitTestFrameworkPkg/Library/UnitTestLib/Log.c
@@ -136,7 +136,7 @@ UnitTestLogInit (
return;
}
- if((Buffer != NULL) && (BufferSize > 0) && ((BufferSize <= UNIT_TEST_MAX_LOG_BUFFER))) {
+ if((Buffer != NULL) && (BufferSize > 0) && (BufferSize <= UNIT_TEST_MAX_LOG_BUFFER)) {
CopyMem (Test->Log, Buffer, BufferSize);
}
}