Junior Spellweaver
- Joined
- Apr 18, 2009
- Messages
- 163
- Reaction score
- 3
Hey Ragezone,
I found out that if i keep my client running, after 2~3 hours it crashes.
First, I saw in the Task Manager that every second the memory usage of the Gunz.exe proccesses is increased infinitly (until the crash).
Then, I tried to debug which part of the code causes this thing, and found out that it is related to the graphic engine that in the end calls to 'MWidget::OnDraw' infinitly.
More Info:
The function RRun() in RFrameWork.cpp calls in infinite loop to g_App.OnDraw();
which calls to Mint::GetInstance()->Draw();
which calls to m_pMainFrame->Draw(pDC);
And this Draw function above (in MWidget.cpp) calls to OnDraw()
When I tried to delete this call to OnDraw() just for testing, I found out that the memory leak is gone!
but of course also the game interface is gone and the screen becomes black - because nothing is renedered anymore.
My questions are:
1. how should i fix it?
2. is it a common issue with Gunzclients?
3. how can i keep render the screen infinitely without causing a memory leak which leads to a crash in the end?
The person who helps will get a kind gift (represented as a code haha)
Thanks!
I found out that if i keep my client running, after 2~3 hours it crashes.
First, I saw in the Task Manager that every second the memory usage of the Gunz.exe proccesses is increased infinitly (until the crash).
Then, I tried to debug which part of the code causes this thing, and found out that it is related to the graphic engine that in the end calls to 'MWidget::OnDraw' infinitly.
More Info:
The function RRun() in RFrameWork.cpp calls in infinite loop to g_App.OnDraw();
which calls to Mint::GetInstance()->Draw();
which calls to m_pMainFrame->Draw(pDC);
And this Draw function above (in MWidget.cpp) calls to OnDraw()
When I tried to delete this call to OnDraw() just for testing, I found out that the memory leak is gone!
but of course also the game interface is gone and the screen becomes black - because nothing is renedered anymore.
My questions are:
1. how should i fix it?
2. is it a common issue with Gunzclients?
3. how can i keep render the screen infinitely without causing a memory leak which leads to a crash in the end?
The person who helps will get a kind gift (represented as a code haha)
Thanks!