diff options
author | Christian Geddes <crgeddes@us.ibm.com> | 2017-09-08 10:22:52 -0500 |
---|---|---|
committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2017-09-25 11:54:57 -0400 |
commit | 1b3b999258db544d6af1dbfb7ee3437efd17581b (patch) | |
tree | 1cb96dd1838af832ef630398c93cfedeaafda3ef /src/usr/scom | |
parent | ac058e9b3c6d1d5d57089d42cbb75b76f36d24a2 (diff) | |
download | blackbird-hostboot-1b3b999258db544d6af1dbfb7ee3437efd17581b.tar.gz blackbird-hostboot-1b3b999258db544d6af1dbfb7ee3437efd17581b.zip |
Set variables to nullptr after they are deleted
While updating some LPC logic a developer noticed a bug where
an errlog handle wasnt getting set to nullptr after it was deleted
this caused a confusing bug that took awhile to track. I noticed
that this bug was all over our code so this commit fixes a lot of
cases where variables get deleted but not set to nullptr
Change-Id: I103b5c71b93686c3c89b04d1d565a24d4de74e6f
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/45890
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Reviewed-by: Matt Derksen <mderkse1@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/scom')
-rw-r--r-- | src/usr/scom/scom.C | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/usr/scom/scom.C b/src/usr/scom/scom.C index d225eac02..72946642f 100644 --- a/src/usr/scom/scom.C +++ b/src/usr/scom/scom.C @@ -814,6 +814,7 @@ errlHndl_t doScomOp(DeviceFW::OperationType i_opType, && (l_err->reasonCode() == IBSCOM::IBSCOM_RETRY_DUE_TO_ERROR) ) { delete l_err; + l_err = nullptr; TRACFCOMP(g_trac_scom, "Forcing retry of Scom to %.16X on %.8X", i_addr, (TARGETING::MASTER_PROCESSOR_CHIP_TARGET_SENTINEL == i_target ? 0xFFFFFFFF : TARGETING::get_huid(i_target))); @@ -927,6 +928,7 @@ void addScomFailFFDC( errlHndl_t i_err, if( l_ignored ) { delete l_ignored; + l_ignored = nullptr; l_scomdata = 0; } else |