Board index » cppbuilder » Why this error? "[Linker Error] Fatal: Access violation. Link terminated."
Veebo
![]() CBuilder Developer |
Why this error? "[Linker Error] Fatal: Access violation. Link terminated."2005-06-16 08:13:19 AM cppbuilder25 Hi guys, I did something simple below. Just declared a global double array of 4 million entries (4,000,000) and i get a linker error: "[Linker Error] Fatal: Access violation. Link terminated." double x[4000000] =~ 32Mb Is that too big? Is that the reason? it was fine with 3million entries. I changed the MAX stack size in BCB ((Project->Options->Linker) to 0x01000000 which is max 16Mb. Does this even matter. It doesn't make sense since the project didn't crash when I tried 3 million entries. So, maybe that is not the deal. What settings do I need to change. I will appreciate your help. here's the code.. basically one line. //------------Unit1.cpp------------------------ #pragma package(smart_init) #pragma resource "*.dfm" TForm1 *Form1; double x[10000000]; //<<<<<<<< this line //--------------------------- __fastcall TForm1::TForm1(TComponent* Owner) : TForm(Owner) { } //-------------------------- thanks, Veebo |