I've a strange problem with my FreeBasic code. I've declared my C++ function "CPC_LOADER" for using this in freebasic, no problem, when I use this function, this works ;) But when I use JUST ONE TIME my c++ function AND I exit my FreeBasic program, i've Segment Violation signal..
My FreeBasic code works properly and exit when I not use 1 C/C++ function (Commented). But he crashs when I use this.. (Not commented)
My C++ code :
Code: Select all
#include <cstring>
#include <sstream>
#include <iostream>
namespace cpinti
{
int cpinti_core::CPC_LOADER()
{
std::cout << " *** C++ execute ***" << std::endl;
return 0;
}
}
PS :
- Forget the lines 24 to 36 !
- I've forgot the return "__CPCDOS_INIT_1 = 0" but it's the same problem
Can you explain, why My freeBasic program Crash at the end when I use one time an C++ Function ?
Regards