How to implement a windbg plugin

 

How to implement a windbg plugin

 

Define EXT_CLASS

 

#include "lauxlib.h"

 

class EXT_CLASS : public ExtExtension

{

public:

                EXT_COMMAND_METHOD(lua);

};

 

EXT_DECLARE_GLOBALS();

 

Impl methods

 

EXT_COMMAND(luado,

                "Execute lua code.",

                "{;x,r;lua string;lua code.}")

{

}

 

Functions can be called in methods:

Get input arguments      LPCSTR lua_code = GetUnnamedArgStr(0);

Error      Err("Cannot find script in code.\r\n");

 

 

Ref: C:\Users\aeejshe\Downloads\luadbg-master\luadbg-master\luadbg\luadbg.cpp

posted on 2018-05-10 19:14  cutepig  阅读(129)  评论(0编辑  收藏  举报

导航