[PATCH 0/3] esx: Remove unnecessary NULL comparisons

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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)

 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(-)

-- 
1.8.1.2

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux