views:

18

answers:

0

When Using DLLs or Code-injecting to be Specific
this is an example class only intended for explaining

class test
{
    int newint1;
    char newchararray[512];
    void (*newfunction1)( int newarg1 );
    int newfunction2( bool newarg1, char newarg2 )
    {
        return newint1;
    }
} mynewclass1;

that covers most common elements that's included in classes
now when exporting this function to another DLL or application
and missed an element of those, either data member or function member, private or public
what happens or changed their order ?
and if each function is assigned it's value when Code-Injecting like

 mynewclass1.newfunction1 = (void *)(newexportedfunction);

what's the happens in this case, if members of the class are pointers that are assigned after class construction and then missed one member or changed their order ?