summaryrefslogtreecommitdiffstats
path: root/Source/kwsys/RegularExpression.cxx
diff options
context:
space:
mode:
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);