summaryrefslogtreecommitdiffstats
path: root/Source/kwsys/RegularExpression.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-05-13 11:08:22 (GMT)
committerBrad King <brad.king@kitware.com>2020-05-13 11:08:22 (GMT)
commit833ae0a63beb790ee606221ee5ce178d08b441ae (patch)
tree8470bdfc58340338d12ba539a47270fcaf0e2b61 /Source/kwsys/RegularExpression.cxx
parentad11526dc477f988d157eb0e78327addc8e9aa5f (diff)
parent3674f6a47000db2b519a44062b8ce46db4f12691 (diff)
downloadCMake-833ae0a63beb790ee606221ee5ce178d08b441ae.zip
CMake-833ae0a63beb790ee606221ee5ce178d08b441ae.tar.gz
CMake-833ae0a63beb790ee606221ee5ce178d08b441ae.tar.bz2
Merge branch 'upstream-KWSys' into update-kwsys
# By KWSys Upstream * upstream-KWSys: KWSys 2020-05-13 (d4da6980)
Diffstat (limited to 'Source/kwsys/RegularExpression.cxx')
-rw-r--r--Source/kwsys/RegularExpression.cxx7
1 files changed, 3 insertions, 4 deletions
diff --git a/Source/kwsys/RegularExpression.cxx b/Source/kwsys/RegularExpression.cxx
index 5e6f8da..4f74eba 100644
--- a/Source/kwsys/RegularExpression.cxx
+++ b/Source/kwsys/RegularExpression.cxx
@@ -28,8 +28,8 @@
# include "RegularExpression.hxx.in"
#endif
-#include <stdio.h>
-#include <string.h>
+#include <cstdio>
+#include <cstring>
namespace KWSYS_NAMESPACE {
@@ -367,8 +367,7 @@ bool RegularExpression::compile(const char* exp)
// Allocate space.
//#ifndef _WIN32
- if (this->program != nullptr)
- delete[] this->program;
+ delete[] this->program;
//#endif
this->program = new char[comp.regsize];
this->progsize = static_cast<int>(comp.regsize);