summaryrefslogtreecommitdiffstats
path: root/c++/src
diff options
context:
space:
mode:
authorSean McBride <sean@rogue-research.com>2021-03-22 17:51:18 (GMT)
committerGitHub <noreply@github.com>2021-03-22 17:51:18 (GMT)
commit38b9474af03909d49cc928c71c190e4f26a15b5c (patch)
treeb8eb735f44b4e246816a4daec9714d5c4d89675e /c++/src
parent60e14b826a22452934f7057196c1ce4d0054d97a (diff)
downloadhdf5-38b9474af03909d49cc928c71c190e4f26a15b5c.zip
hdf5-38b9474af03909d49cc928c71c190e4f26a15b5c.tar.gz
hdf5-38b9474af03909d49cc928c71c190e4f26a15b5c.tar.bz2
Applied clang-tidy readability-delete-null-pointer fixes (#430)
delete nullptr is well-defined, does not need check. Manually fixed indentation after automatic changes.
Diffstat (limited to 'c++/src')
-rw-r--r--c++/src/H5DaccProp.cpp3
-rw-r--r--c++/src/H5DataSpace.cpp3
-rw-r--r--c++/src/H5DcreatProp.cpp3
-rw-r--r--c++/src/H5DxferProp.cpp3
-rw-r--r--c++/src/H5FaccProp.cpp3
-rw-r--r--c++/src/H5FcreatProp.cpp3
-rw-r--r--c++/src/H5LaccProp.cpp3
-rw-r--r--c++/src/H5LcreatProp.cpp3
-rw-r--r--c++/src/H5OcreatProp.cpp3
-rw-r--r--c++/src/H5PropList.cpp3
10 files changed, 10 insertions, 20 deletions
diff --git a/c++/src/H5DaccProp.cpp b/c++/src/H5DaccProp.cpp
index 35c071a..1905f27 100644
--- a/c++/src/H5DaccProp.cpp
+++ b/c++/src/H5DaccProp.cpp
@@ -72,8 +72,7 @@ DSetAccPropList::getConstant()
void
DSetAccPropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5DataSpace.cpp b/c++/src/H5DataSpace.cpp
index 0485530..c20a88c 100644
--- a/c++/src/H5DataSpace.cpp
+++ b/c++/src/H5DataSpace.cpp
@@ -69,8 +69,7 @@ DataSpace::getConstant()
void
DataSpace::deleteConstants()
{
- if (ALL_ != 0)
- delete ALL_;
+ delete ALL_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5DcreatProp.cpp b/c++/src/H5DcreatProp.cpp
index 383e38f..34be7ba 100644
--- a/c++/src/H5DcreatProp.cpp
+++ b/c++/src/H5DcreatProp.cpp
@@ -78,8 +78,7 @@ DSetCreatPropList::getConstant()
void
DSetCreatPropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5DxferProp.cpp b/c++/src/H5DxferProp.cpp
index 2b50de4..43ea6f4 100644
--- a/c++/src/H5DxferProp.cpp
+++ b/c++/src/H5DxferProp.cpp
@@ -72,8 +72,7 @@ DSetMemXferPropList::getConstant()
void
DSetMemXferPropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5FaccProp.cpp b/c++/src/H5FaccProp.cpp
index 926ac2f..a79ada3 100644
--- a/c++/src/H5FaccProp.cpp
+++ b/c++/src/H5FaccProp.cpp
@@ -76,8 +76,7 @@ FileAccPropList::getConstant()
void
FileAccPropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5FcreatProp.cpp b/c++/src/H5FcreatProp.cpp
index b9be563..b51ba10 100644
--- a/c++/src/H5FcreatProp.cpp
+++ b/c++/src/H5FcreatProp.cpp
@@ -68,8 +68,7 @@ FileCreatPropList::getConstant()
void
FileCreatPropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5LaccProp.cpp b/c++/src/H5LaccProp.cpp
index feaa555..acdaa13 100644
--- a/c++/src/H5LaccProp.cpp
+++ b/c++/src/H5LaccProp.cpp
@@ -70,8 +70,7 @@ LinkAccPropList::getConstant()
void
LinkAccPropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5LcreatProp.cpp b/c++/src/H5LcreatProp.cpp
index 29721c1..63fe861 100644
--- a/c++/src/H5LcreatProp.cpp
+++ b/c++/src/H5LcreatProp.cpp
@@ -70,8 +70,7 @@ LinkCreatPropList::getConstant()
void
LinkCreatPropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5OcreatProp.cpp b/c++/src/H5OcreatProp.cpp
index 81dae31..dffdeb1 100644
--- a/c++/src/H5OcreatProp.cpp
+++ b/c++/src/H5OcreatProp.cpp
@@ -70,8 +70,7 @@ ObjCreatPropList::getConstant()
void
ObjCreatPropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------
diff --git a/c++/src/H5PropList.cpp b/c++/src/H5PropList.cpp
index 28ab44e..8b45f79 100644
--- a/c++/src/H5PropList.cpp
+++ b/c++/src/H5PropList.cpp
@@ -71,8 +71,7 @@ PropList::getConstant()
void
PropList::deleteConstants()
{
- if (DEFAULT_ != 0)
- delete DEFAULT_;
+ delete DEFAULT_;
}
//--------------------------------------------------------------------------