[Scummvm-cvs-logs] CVS: residual costume.cpp,1.2,1.3

James Brown ender at users.sourceforge.net
Tue Aug 19 09:29:01 CEST 2003


Update of /cvsroot/scummvm/residual
In directory sc8-pr-cvs1:/tmp/cvs-serv3158

Modified Files:
	costume.cpp 
Log Message:
If ecchi is bad, memory leaks are evil :)


Index: costume.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/costume.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- costume.cpp	19 Aug 2003 12:27:17 -0000	1.2
+++ costume.cpp	19 Aug 2003 14:02:25 -0000	1.3
@@ -34,6 +34,8 @@
   BitmapComponent(Costume::Component *parent, int parentID,
 		 const char *filename);
   BitmapComponent *copy(Costume::Component *newParent);
+  ~BitmapComponent();
+
   void update();
   void draw();
 
@@ -105,6 +107,14 @@
 
   bitmap_ = ResourceLoader::instance()->loadBitmap(filename);
   warning("Instanced BitmapComponenet from Costume renderer: NOT IMPLEMENTED YET");
+}
+
+BitmapComponent::~BitmapComponent() {
+  if (bitmap_)
+	delete[] bitmap_;
+
+  if (zbuffer_)
+	delete[] zbuffer_;
 }
 
 BitmapComponent *BitmapComponent::copy(Costume::Component *newParent) {





More information about the Scummvm-git-logs mailing list