aboutsummaryrefslogtreecommitdiff
path: root/src/util.cpp
diff options
context:
space:
mode:
authorMatt Corallo <[email protected]>2011-05-26 02:24:01 +0200
committerMatt Corallo <[email protected]>2011-05-26 02:24:01 +0200
commit77172463a30a5837a0a53ddfd7fb578343d2a33f (patch)
treef08f23b9a89eea7802855cef4845dcf842e3e008 /src/util.cpp
parentUpdated dutch translation (diff)
downloaddiscoin-77172463a30a5837a0a53ddfd7fb578343d2a33f.tar.xz
discoin-77172463a30a5837a0a53ddfd7fb578343d2a33f.zip
Fixes #240 and #244 - delete delete[] mismatch.
Diffstat (limited to 'src/util.cpp')
-rw-r--r--src/util.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/util.cpp b/src/util.cpp
index 4e93f625d..619910928 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -271,7 +271,7 @@ string strprintf(const char* format, ...)
if (ret >= 0 && ret < limit)
break;
if (p != buffer)
- delete p;
+ delete[] p;
limit *= 2;
p = new char[limit];
if (p == NULL)
@@ -279,7 +279,7 @@ string strprintf(const char* format, ...)
}
string str(p, p+ret);
if (p != buffer)
- delete p;
+ delete[] p;
return str;
}