2010-06-19 18:50:37 -06:00
|
|
|
#include <iostream>
|
|
|
|
#include <iomanip>
|
|
|
|
#include <climits>
|
|
|
|
#include <vector>
|
|
|
|
#include <sstream>
|
|
|
|
#include <ctime>
|
|
|
|
#include <cstdio>
|
|
|
|
using namespace std;
|
|
|
|
|
|
|
|
#include <DFHack.h>
|
|
|
|
using namespace DFHack;
|
|
|
|
|
|
|
|
int main (int numargs, const char ** args)
|
|
|
|
{
|
|
|
|
DFHack::ContextManager DFMgr("Memory.xml");
|
|
|
|
DFHack::Context * DF;
|
|
|
|
try
|
|
|
|
{
|
|
|
|
DF = DFMgr.getSingleContext();
|
|
|
|
DF->Attach();
|
|
|
|
}
|
|
|
|
catch (exception& e)
|
|
|
|
{
|
|
|
|
cerr << e.what() << endl;
|
|
|
|
#ifndef LINUX_BUILD
|
|
|
|
cin.ignore();
|
|
|
|
#endif
|
|
|
|
return 1;
|
|
|
|
}
|
2010-08-20 06:10:05 -06:00
|
|
|
VersionInfo * minfo = DF->getMemoryInfo();
|
2010-06-19 18:50:37 -06:00
|
|
|
if(minfo)
|
|
|
|
cout << minfo->PrintOffsets();
|
|
|
|
#ifndef LINUX_BUILD
|
|
|
|
cout << "Done. Press any key to continue" << endl;
|
|
|
|
cin.ignore();
|
|
|
|
#endif
|
|
|
|
return 0;
|
|
|
|
}
|