Click here to Skip to main content
15,919,028 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Libraries Pin
Zizilamoroso11-Sep-03 2:08
Zizilamoroso11-Sep-03 2:08 
GeneralRe: Libraries Pin
jhwurmbach11-Sep-03 2:10
jhwurmbach11-Sep-03 2:10 
GeneralDialog Help Pin
10-Sep-03 23:23
suss10-Sep-03 23:23 
GeneralRe: Dialog Help Pin
Iain Clarke, Warrior Programmer10-Sep-03 23:44
Iain Clarke, Warrior Programmer10-Sep-03 23:44 
GeneralSDI linkage with dialog Pin
coda_x10-Sep-03 23:21
coda_x10-Sep-03 23:21 
GeneralHorrid Memory Management Issue Pin
Dangleberry10-Sep-03 22:30
sussDangleberry10-Sep-03 22:30 
GeneralRe: Horrid Memory Management Issue Pin
Phil Speller10-Sep-03 23:20
Phil Speller10-Sep-03 23:20 
GeneralRe: Horrid Memory Management Issue Pin
Dangleberry10-Sep-03 23:59
sussDangleberry10-Sep-03 23:59 
Yes, I had thought about allocating a couple of extra places and then when they are filled grabbing a new block and copying the contents in, which is essentially what realloc utilises. This is definitely one option, and is probably the way that the vector class works (in fact you can define its growth factor). However, I was hoping to come up with a nice tight memory usage, that makes things easy to use. The idea of placement new seems like what I want, 'use this memory address to initialise with this item'. I don't think it actually allocates any memory see, just initialises it with the item you supply. As you stated, I'd then have to whip through the array and call the destructor for each object manually, but this can be arranged Smile | :) . If realloc needed a new memory block, the contents of my already initialise data would be copied in - no destructor is called, which is great because it were, when the array class destructor was called it would delete the same objects again Smile | :) . I think I may be on the right lines, just waiting for someone to prove otherwise Smile | :) . Thanks for your comments though Phil, they were very encouraging, which is something I need at the minute cos I've been on this a little while Smile | :) .

Many Thanks,
Alan.
GeneralRe: Horrid Memory Management Issue Pin
Phil Speller11-Sep-03 1:37
Phil Speller11-Sep-03 1:37 
GeneralRe: Horrid Memory Management Issue Pin
Dangleberry11-Sep-03 2:31
sussDangleberry11-Sep-03 2:31 
GeneralRe: Horrid Memory Management Issue Pin
Phil Speller10-Sep-03 23:50
Phil Speller10-Sep-03 23:50 
GeneralRe: Horrid Memory Management Issue Pin
Dangleberry11-Sep-03 0:14
sussDangleberry11-Sep-03 0:14 
GeneralRe: Horrid Memory Management Issue Pin
antlers11-Sep-03 9:39
antlers11-Sep-03 9:39 
GeneralRe: Horrid Memory Management Issue Pin
Dangleberry11-Sep-03 23:15
sussDangleberry11-Sep-03 23:15 
GeneralProblem handling pictures Pin
abhi197110-Sep-03 22:19
abhi197110-Sep-03 22:19 
GeneralRe: Problem handling pictures Pin
Dangleberry10-Sep-03 22:37
sussDangleberry10-Sep-03 22:37 
GeneralRe: Problem handling pictures Pin
abhi197110-Sep-03 22:51
abhi197110-Sep-03 22:51 
GeneralRe: Problem handling pictures Pin
Dangleberry10-Sep-03 22:58
sussDangleberry10-Sep-03 22:58 
GeneralRe: Problem handling pictures Pin
abhi197110-Sep-03 23:02
abhi197110-Sep-03 23:02 
GeneralRe: Problem handling pictures Pin
Dangleberry10-Sep-03 23:41
sussDangleberry10-Sep-03 23:41 
GeneralRe: Problem handling pictures Pin
Jagadeesh VN11-Sep-03 4:51
Jagadeesh VN11-Sep-03 4:51 
GeneralRe: Problem handling pictures Pin
abhi197111-Sep-03 22:36
abhi197111-Sep-03 22:36 
GeneralSocket programming in Visual C++ 6 Pin
fahimtufaillara10-Sep-03 21:55
fahimtufaillara10-Sep-03 21:55 
GeneralRe: Socket programming in Visual C++ 6 Pin
R. Thomas10-Sep-03 22:11
R. Thomas10-Sep-03 22:11 
GeneralRe: Socket programming in Visual C++ 6 Pin
Jagadeesh VN11-Sep-03 4:58
Jagadeesh VN11-Sep-03 4:58 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.