Go4Expert

Go4Expert (http://www.go4expert.com/)
-   C (http://www.go4expert.com/forums/c/)
-   -   how to implement poisoning concept in memory allocation (http://www.go4expert.com/forums/implement-poisoning-concept-memory-t12093/)

jeya 14Jul2008 17:13

how to implement poisoning concept in memory allocation
 
hi all,


In my program,a user defined function is created which internally uses malloc() and free().

But I dont know how to create header and footer for the allocated memory.

And poisoning concept should be implemented checking the header and footer areas to know whether user has exceeded memory space or not.If so,allocated memory will be deallocated.

pls tell me how to implement the poisoning concept

xpi0t0s 16Jul2008 14:15

Re: how to implement poisoning concept in memory allocation
 
It's not clear (to me anyway) what you mean. What is poisoning, and what does that have to do with user quotas? What is the purpose of the header and footer, and what do they contain? Where will the header and footer be used, and to what end?
If a memory request means the user will exceed their quota then perhaps it would be better not to allocate the memory in the first place.


All times are GMT +5.5. The time now is 01:48.