Re: [edk2] [PATCH v1 1/2] MdeModulePkg/NetLib.h: Fix the possible NULL pointer dereference issue.

2019-01-16 Thread Wu, Jiaxin
Hi Laszlo, Thanks review the patch. > > (1) The linked list from BaseLib (LIST_ENTRY) always has at least one > element (the head element), and the list is empty if the head element > points back to itself. In other words, ForwardLink may never be NULL. > > So why is it necessary to check again

Re: [edk2] [PATCH v1 1/2] MdeModulePkg/NetLib.h: Fix the possible NULL pointer dereference issue.

2019-01-15 Thread Laszlo Ersek
Hi Jiaxin, On 01/15/19 02:26, Jiaxin Wu wrote: > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1456 > > For the NET_LIST_FOR_EACH & NET_LIST_FOR_EACH_SAFE, "Entry" should be > checked whether it's NULL or not instead of using the pointer directly. > > Cc: Wu Hao A > Cc: Gao Liming > Cc:

[edk2] [PATCH v1 1/2] MdeModulePkg/NetLib.h: Fix the possible NULL pointer dereference issue.

2019-01-14 Thread Jiaxin Wu
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1456 For the NET_LIST_FOR_EACH & NET_LIST_FOR_EACH_SAFE, "Entry" should be checked whether it's NULL or not instead of using the pointer directly. Cc: Wu Hao A Cc: Gao Liming Cc: Ye Ting Cc: Fu Siyuan Contributed-under: TianoCore Contributio