Old-Ding opened a new pull request, #19325: URL: https://github.com/apache/nuttx/pull/19325
## Summary - fix two PCI EPF `DEBUGASSERT()` precondition checks - require both the object pointer and the required member/callback to be non-NULL ## Why `pci_epf_device_register()` asserted `epf != NULL || epf->name != NULL`, and `pci_epf_unregister_driver()` asserted `drv != NULL || drv->remove != NULL`. With `||`, a NULL object still evaluates the right-hand side and can dereference NULL in debug builds, while a non-NULL object with a missing required member passes the assertion. ## Testing - `git diff --check origin/master...HEAD` - `git show --stat --check --format=fuller HEAD` - Not run: local NuttX build, because this Windows workstation does not have the required C build toolchain installed. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
