On 05/24/18 16:41, Ard Biesheuvel wrote:
> On 24 May 2018 at 16:39, Laszlo Ersek <[email protected]> wrote:
>> On 05/24/18 09:53, Ard Biesheuvel wrote:
>>>> +RETURN_STATUS
>>>> +EFIAPI
>>>> +PciCapGetInfo (
>>>> + IN PCI_CAP *Cap,
>>>> + OUT PCI_CAP_INFO *Info
>>>> + )
>>>> +{
>>>> + PCI_CAP *InstanceZero;
>>>> +
>>>
>>> Nit: add
>>>
>>> ASSERT (Info != NULL);
>>>
>>> here?
>>>
>>> I know it seems rather arbitrary to add it here and not anywhere else,
>>> but PciCapGetInfo() is part of the API, and dereferencing Info [which
>>> may be the result of e.g., a pool allocation] for writing is
>>> particularly bad.
>>
>>
>> I will add the ASSERT().
>>
>> (I hope I didn't miss any of your comments!)
>>
>
> It's just a nit, feel free to ignore.
>
> In any case,
>
> Reviewed-by: Ard Biesheuvel <[email protected]>
>
Thanks! I'll add the ASSERT.
Laszlo
_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.01.org/mailman/listinfo/edk2-devel