[Spice-devel] [PATCH 2/5] client: match delete[] with new[]
Christophe Fergeau
cfergeau at redhat.com
Fri Jul 8 03:17:29 PDT 2011
vinfo in x11/platform.cpp is allocated using new[] so it needs to
be freed with delete[]
---
client/x11/platform.cpp | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/client/x11/platform.cpp b/client/x11/platform.cpp
index 7c31058..910d61e 100644
--- a/client/x11/platform.cpp
+++ b/client/x11/platform.cpp
@@ -2881,7 +2881,7 @@ static void cleanup(void)
for (i = 0; i < ScreenCount(x_display); ++i) {
XFree(vinfo[i]);
}
- delete vinfo;
+ delete[] vinfo;
vinfo = NULL;
}
#ifdef USE_OPENGL
--
1.7.6
More information about the Spice-devel
mailing list