MSVC++ err msg : "scalar deleting destructor returned"

Started by
1 comment, last by nosajghoul 20 years, 6 months ago
What does this mean - "scalar deleting destructor returned" ????? Ive tried looking it up on microsofts site.. no luck Ive put it in the google search box... nothing I cant for the life of me finger this one out. Basically, it occurs after I try to delete a pointer. Heres a copy of the destructor code that gets called :


cVideo::~cVideo()
{	
    pVW->put_Visible(OAFALSE);
    pVW->put_Owner(NULL);

    // Disable event notification before releasing the graph.
    pEvent->SetNotifyWindow(NULL, 0, 0);
    pEvent->Release();
    pEvent = NULL;

    // Stop the graph.
    pMediaControl->Stop();

	pVW->Release(); pVW = NULL;
	
	pMediaControl->Release(); pMediaControl = NULL;
	
	pGraph->Release(); pGraph = NULL;
	
	CoUninitialize();
}

 
Prolly something simple I didnt know.... AGAIN!! -Jason
normal_toes@hotmail.com
Advertisement
Are you perhaps using scalar delete on an array in one of those cleanup calls? Instead of array delete[]?


[My site|SGI STL|Bjarne FAQ|C++ FAQ Lite|MSDN|Jargon]
Ripped off from various people
[size=2]
Could be... not sure, could use some edumacating on the subject.

Im not deleting an array.

Heres some relevant code :

In main.cpp, cVideo is declared globally. Its basically a simple class that makes using DirectShow easier.
#include "cVideo.h"cVideo *video = NULL;//for event messages from a direct show window#define WM_GRAPHNOTIFY  WM_APP + 1 #define CLASSNAME "EventNotify" 


After your standard non-MFC way of creating a window, video is initialized, used, then deleted (upon which I get that error)
	video = new cVideo;	video->PlayVideo(1);	delete video; 


Still dazed and confused.
-Jason
normal_toes@hotmail.com

This topic is closed to new replies.

Advertisement