diff test/form.cc @ 2016:8cf59505bd0a

tests cleanup
author corvid <corvid@lavabit.com>
date Sat, 14 May 2011 06:45:42 +0000
parents 02ef25700865
children
line wrap: on
line diff
--- a/test/form.cc	Sat May 14 06:43:17 2011 +0000
+++ b/test/form.cc	Sat May 14 06:45:42 2011 +0000
@@ -32,7 +32,7 @@
 
 Form::ResourceDecorator::~ResourceDecorator ()
 {
-   delete name;
+   free((char *)name);
 }
 
 Form::TextResourceDecorator::TextResourceDecorator (const char *name,
@@ -57,15 +57,15 @@
    while (values[n])
       n++;
    this->values = new const char*[n + 1];
-   for(int i = 0; i < n; i++)
+   for (int i = 0; i < n; i++)
       this->values[i] = strdup (values[i]);
    this->values[n] = 0;
 }
 
 Form::RadioButtonResourceDecorator::~RadioButtonResourceDecorator ()
 {
-   for(int i = 0; values[i]; i++)
-      delete values[i];
+   for (int i = 0; values[i]; i++)
+      free((char *)values[i]);
    delete[] values;
 }
 
@@ -115,7 +115,7 @@
 Form::SelectionResourceDecorator::~SelectionResourceDecorator ()
 {
    for(int i = 0; values[i]; i++)
-      delete values[i];
+      free((char *)values[i]);
    delete[] values;
 }
 
@@ -159,8 +159,8 @@
 
 Form::FormClickedReceiver::~FormClickedReceiver ()
 {
-   delete name;
-   delete[] value;
+   free((char *)name);
+   free((char *)value);
 }
 
 void Form::FormClickedReceiver::clicked (Resource *resource,