Skip to content

Commit 5a88838

Browse files
stewartsmithdcrowell77
authored andcommitted
Fix build error: nonnull argument compared to NULL
Shows up in GCC6: chips/p9/procedures/hwp/memory/lib/utils/find.H:437:5: error nonnull argument ?i_array? compared to NULL [-Werror=nonnull-compare] Change-Id: I25db14d9d9875c1f61f894b3d0df4dda6100f44d Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/37856 Reviewed-by: JACOB L. HARVEY <jlharvey@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Reviewed-by: ANDRE A. MARIN <aamarin@us.ibm.com> Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com> Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/36982 Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
1 parent 6f56050 commit 5a88838

File tree

1 file changed

+0
-6
lines changed
  • src/import/chips/p9/procedures/hwp/memory/lib/utils

1 file changed

+0
-6
lines changed

src/import/chips/p9/procedures/hwp/memory/lib/utils/find.H

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -434,12 +434,6 @@ fapi2::ReturnCode find_value_from_key( const std::pair<T, OT> (&i_array)[N],
434434
OT& o_value)
435435
{
436436
// TK Use sort and binary search for larger arrays
437-
if (i_array == nullptr)
438-
{
439-
FAPI_ERR("nullptr passed to the find_value_from_key function");
440-
return fapi2::FAPI2_RC_INVALID_PARAMETER;
441-
}
442-
443437
for (size_t i = 0; i < N; i++)
444438
{
445439
if (i_array[i].first == i_key)

0 commit comments

Comments
 (0)