public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* Re: Repeated condition check
@ 2017-09-22  8:40 Santhapur Naveen
  2017-09-25  5:02 ` Wu, Jiaxin
  0 siblings, 1 reply; 6+ messages in thread
From: Santhapur Naveen @ 2017-09-22  8:40 UTC (permalink / raw)
  To: edk2-devel@lists.01.org

Hello guys,

Any update?

Thank you
Naveen

-----Original Message-----
From: Santhapur Naveen 
Sent: Wednesday, September 20, 2017 12:05 PM
To: edk2-devel@lists.01.org
Subject: Repeated condition check

Hi all,

There is a redundant condition check in the API PxeBcIcmp6ErrorDpcHandle()

VOID
EFIAPI
PxeBcIcmp6ErrorDpcHandle (
  IN VOID                 *Context
  )
{
 ...

  if (Type != ICMP_V6_DEST_UNREACHABLE &&
      Type != ICMP_V6_PACKET_TOO_BIG &&
    -Type != ICMP_V6_PACKET_TOO_BIG &&
    +Type != ICMP_V6_TIME_EXCEEDED &&
      Type != ICMP_V6_PARAMETER_PROBLEM) {
    //
    // The type of the receveid packet should be an ICMP6 error message.
    //
    gBS->SignalEvent (RxData->RecycleSignal);
    goto ON_EXIT;
  }
  ...
}

Unfortunately, some error checking tools were not able to capture this.
Please confirm and take the necessary action.

Thank you
Naveen


^ permalink raw reply	[flat|nested] 6+ messages in thread
* Repeated condition check
@ 2017-09-20  6:35 Santhapur Naveen
  0 siblings, 0 replies; 6+ messages in thread
From: Santhapur Naveen @ 2017-09-20  6:35 UTC (permalink / raw)
  To: edk2-devel@lists.01.org

Hi all,

There is a redundant condition check in the API PxeBcIcmp6ErrorDpcHandle()

VOID
EFIAPI
PxeBcIcmp6ErrorDpcHandle (
  IN VOID                 *Context
  )
{
 ...

  if (Type != ICMP_V6_DEST_UNREACHABLE &&
      Type != ICMP_V6_PACKET_TOO_BIG &&
    -Type != ICMP_V6_PACKET_TOO_BIG &&
    +Type != ICMP_V6_TIME_EXCEEDED &&
      Type != ICMP_V6_PARAMETER_PROBLEM) {
    //
    // The type of the receveid packet should be an ICMP6 error message.
    //
    gBS->SignalEvent (RxData->RecycleSignal);
    goto ON_EXIT;
  }
  ...
}

Unfortunately, some error checking tools were not able to capture this.
Please confirm and take the necessary action.

Thank you
Naveen


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-09-25  5:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-09-22  8:40 Repeated condition check Santhapur Naveen
2017-09-25  5:02 ` Wu, Jiaxin
2017-09-25  5:05   ` Santhapur Naveen
2017-09-25  5:10     ` Wu, Jiaxin
2017-09-25  5:12       ` Santhapur Naveen
  -- strict thread matches above, loose matches on Subject: below --
2017-09-20  6:35 Santhapur Naveen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox