Dump all xex2 headers in XUserModule (minus a couple)

This commit is contained in:
Dr. Chat
2015-07-02 22:00:45 -05:00
parent 362a521c79
commit 82ec1c345d
3 changed files with 159 additions and 16 deletions

View File

@@ -31,6 +31,7 @@ class XUserModule : public XModule {
}
const xex2_header* xex_header() const { return xex_module()->xex_header(); }
uint32_t guest_xex_header() const { return guest_xex_header_; }
uint32_t entry_point() const { return entry_point_; }
uint32_t stack_size() const { return stack_size_; }
@@ -43,8 +44,10 @@ class XUserModule : public XModule {
X_STATUS GetSection(const char* name, uint32_t* out_section_data,
uint32_t* out_section_size) override;
// Get optional header - FOR HOST USE ONLY!
X_STATUS GetOptHeader(xe_xex2_header_keys key, void** out_ptr);
// Get optional header that can safely be returned to guest code.
X_STATUS GetOptHeader(xe_xex2_header_keys key,
uint32_t* out_header_guest_ptr);
static X_STATUS GetOptHeader(uint8_t* membase, const xex2_header* header,