[0.3.x] added : getSystemVersion

git-svn-id: https://pykd.svn.codeplex.com/svn@84372 9b283d60-5439-405e-af05-b73fd8c4d996
This commit is contained in:
SND\kernelnet_cp 2013-07-19 16:02:49 +00:00 committed by Mikhail I. Izmestev
parent c2948f8320
commit a07e0a848d
3 changed files with 21 additions and 2 deletions

View File

@ -155,4 +155,21 @@ python::tuple findSymbolAndDisp( ULONG64 offset )
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
python::dict getSystemVersion()
{
kdlib::SystemInfo sysInfo;
kdlib::getSystemInfo( sysInfo );
python::dict dct;
dct["majorVersion"] = sysInfo.majorVersion;
dct["minorVersion"] = sysInfo.minorVersion;
dct["buildNumber"] = sysInfo.buildNumber;
dct["buildDescription"] = sysInfo.buildDescription;
return dct;
}
///////////////////////////////////////////////////////////////////////////////
} //end namespace pykd } //end namespace pykd

View File

@ -25,6 +25,8 @@ python::tuple getSourceLine( kdlib::MEMOFFSET_64 offset = 0 );
python::tuple findSymbolAndDisp( ULONG64 offset ); python::tuple findSymbolAndDisp( ULONG64 offset );
python::dict getSystemVersion();
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
} //end namespace pykd } //end namespace pykd

View File

@ -140,8 +140,8 @@ BOOST_PYTHON_MODULE( pykd )
"Return the number of seconds the computer has been running" ); "Return the number of seconds the computer has been running" );
python::def( "currentTime", &kdlib::getCurrentTime, python::def( "currentTime", &kdlib::getCurrentTime,
"Return the number of seconds since the beginning of 1970" ); "Return the number of seconds since the beginning of 1970" );
//python::def("getSystemVersion", &getSystemVersion, python::def("getSystemVersion", &getSystemVersion,
// "Return systemVersion"); "Return systemVersion");
// Manage target memory access // Manage target memory access
python::def( "addr64", &kdlib::addr64, python::def( "addr64", &kdlib::addr64,