A bit of checking in some places.

develop
Petr Mrázek 2010-08-14 18:32:38 +02:00
parent a159707250
commit 94872b8abd
3 changed files with 7 additions and 3 deletions

@ -59,7 +59,6 @@ Context::Context (Process* p) : d (new DFContextShared())
Context::~Context() Context::~Context()
{ {
cerr << "called Context destructor" << endl;
Detach(); Detach();
delete d; delete d;
} }

@ -123,7 +123,6 @@ Maps::Maps(DFContextShared* _d)
Maps::~Maps() Maps::~Maps()
{ {
cerr << "called Maps destructor" << endl;
if(d->Started) if(d->Started)
Finish(); Finish();
delete d; delete d;

@ -106,7 +106,13 @@ int main (void)
if(cont) if(cont)
{ {
if(cont->Attach()) if(cont->Attach())
cont->getMaps(); {
DFHack::Maps * mapz = cont->getMaps();
cont->Suspend();
mapz->Start();
cont->Resume();
}
bool result = cont->Detach(); bool result = cont->Detach();
if(!result) if(!result)
{ {