Add missing file

develop
Petr Mrázek 2010-04-11 13:20:15 +02:00
parent 5ef87773be
commit 1e6b5bf8d6
1 changed files with 41 additions and 0 deletions

@ -0,0 +1,41 @@
// Make stuck DF run again.
#include <iostream>
#include <climits>
#include <integers.h>
#include <vector>
#include <ctime>
#include <string>
using namespace std;
#include <DFTypes.h>
#include <DFHackAPI.h>
int main (void)
{
string blah;
DFHack::API DF("Memory.xml");
try
{
DF.Attach();
}
catch (exception& e)
{
cerr << e.what() << endl;
#ifndef LINUX_BUILD
cin.ignore();
#endif
return 1;
}
DF.ForceResume();
cout << "DF should be running again :)" << endl;
getline(cin, blah);
if(!DF.Detach())
{
cerr << "Can't detach from DF" << endl;
return 1;
}
return 0;
}