I'm playing with Enigma demo 3.110
Here is the problem:
Code: Select all
int foo(..) { cout << "foo()\n"; ... }
int bar(..) { cout << "bar()\n"; ... }
int main(..)
{
int (*action)(int, char**);
# include <EnigmaSDK/VC/unreg_crypt_begin1.inc>
action = foo;
cout << "unreg section" << endl;
# include <EnigmaSDK/VC/unreg_crypt_end1.inc>
# include <EnigmaSDK/VC/reg_crypt_begin1.inc>
action = bar;
cout << "reg section" << endl;
# include <EnigmaSDK/VC/reg_crypt_end1.inc>
return action(argc, argv);
}
and in registered:unreg section
foo()
But actually I see the following in unregistered app:reg section
bar()
How this possible, I thought only one of the sections will be executed?unreg section
bar()
Thanks.
