Go Back   EQEmulator Home > EQEmulator Forums > Archives > Archive::Development > Archive::Development

Archive::Development Archive area for Development's posts that were moved here after an inactivity period of 90 days.

Reply
 
Thread Tools Display Modes
  #1  
Old 11-17-2003, 03:21 AM
Merth
Dragon
 
Join Date: May 2003
Location: Seattle, WA
Posts: 609
Default

This is how I interpreted your argument:

When an exception is thrown, stack memory is cleaned up, but heap memory is not. Pointers are on the stack, but the memory they point to is on the heap. When an exception is thrown, we have a mem leak for whatever a stack pointer was pointing to. Wrapping the pointer into a smart pointer will avoid this situation.

However, I do see some issues:
* Most of the team codes in C.
* What are the situations that would cause an exception to be thrown?
* What is the typical way to cache a wrapped pointer? (one that works on linux, so no GIT)
* With regard to auto_ptr, how would it know whether to call delete versus delete[]?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 01:49 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3