
On 10/17/2013 11:04 AM, Geoff Hickey wrote:
In reply to my last submit, Eric Blake suggested removing an explicit NULL comparison, and instead to simply use the pointer in a boolean context, as in: if (ptr) instead of if (ptr != NULL). Since the second form was used thoughout the esx code, making this change in one place wouldn't have advanced the cause of consistency in the code. This series of patches makes this change throughout the esx code. There are no logic changes. The result is (arguably) easier to read.
Geoff Hickey (3): esx: Remove unnecessary NULL comparisons (1/3) esx: Remove unnecessary NULL comparisons (2/3) esx: Remove unnecessary NULL comparisons (3/3)
I didn't read every line of the diff, but it looked fairly mechanical and the places where I did spot check were correct. ACK and pushed.
src/esx/esx_driver.c | 244 +++++++++--------- src/esx/esx_interface_driver.c | 10 +- src/esx/esx_network_driver.c | 64 ++--- src/esx/esx_storage_backend_iscsi.c | 44 ++-- src/esx/esx_storage_backend_vmfs.c | 86 +++---- src/esx/esx_storage_driver.c | 6 +- src/esx/esx_util.c | 48 ++-- src/esx/esx_vi.c | 475 ++++++++++++++++++------------------ src/esx/esx_vi_methods.c | 10 +- src/esx/esx_vi_types.c | 88 +++---- 10 files changed, 535 insertions(+), 540 deletions(-)
-- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org