News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

Don't bend down in front of Memory Management

Started by K_F, October 29, 2015, 08:50:31 PM

Previous topic - Next topic

K_F

Hell's, I've been screwed over this week by memory management.. :icon_eek:
Changed the memory system and bang.. crash after crash after crash.... oh, crap!!!

Eventually found out (or it worked for me anyway) that when HeapAllocating a few independent blocks... I had to HeapFree all of them, and reallocate.
I couldn't free one block and keep the rest, as my proggie would always crash at the HeapFree API  :shock:
(I do have valid handle checks before HeapFree)

Does this sound right to anyone ??
'Sire, Sire!... the peasants are Revolting !!!'
'Yes, they are.. aren't they....'

hutch--

No it doesn't actually, is it something silly like having the wrong pointer for the latter ones ?

K_F

yup.. you're right..

EAX <> EBX... :redface: :redface:

All working again.... I need a beer!!  :t
'Sire, Sire!... the peasants are Revolting !!!'
'Yes, they are.. aren't they....'

dedndave


K_F

Only one mistake i made.. and it threw me  :biggrin:... this is why I like Masm... you have to do it right first time  8)

Quoteinteresting looking project
It is... I'm doing it  :badgrin: .. joking.

I made this big plan about year ago... although it's been it the brain for about 5 years.. it was a matter of getting down to it.
This is just one of the child windows 'of creation' - the one that gave me the problem to start with..
Must finish the winsync graphing bit.. tomorrow - everything's ready when the memory thing bombed me..

Roll your own filters, add a bit of AI... take a swig of wine.. and bingo... well yes.. bingo! ;)

'Sire, Sire!... the peasants are Revolting !!!'
'Yes, they are.. aren't they....'

Zen

K_F/VAN,
You're writing a signal processing program ???
...In assembly ???   

K_F

It's not that difficult... just the small things get you.. like using the wrong register :biggrin:
Most of it is all in place... I was going through the graphic representation (that dark square ).. but got held up a little with this memory management.

I keep on changing things as I find more efficient way of doing things... must control myself  :badgrin:
'Sire, Sire!... the peasants are Revolting !!!'
'Yes, they are.. aren't they....'