Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > Re: finding out if pointer to memory is valid

Reply
Thread Tools

Re: finding out if pointer to memory is valid

 
 
Ron Natalie
Guest
Posts: n/a
 
      06-26-2003

"Schelli" <(E-Mail Removed)> wrote in message news:(E-Mail Removed) m...

>
> can i somehow find out that the memory this pointer is pointing to was
> deleted ? or do i just have to find a way to set the other pointer to
> NULL so i know.


There is no way to determine if a pointer points to something valid
or not. You'll need to keep track of it seperately (either whether it
is deleted, or have reference count so that the object is not deleted
while people are still using it).


 
Reply With Quote
 
 
 
Reply

Thread Tools

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
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to check whether malloc has allocated memory properly in case ifmalloc(0) can return valid pointer Shivanand Kadwadkar C Programming 83 01-08-2011 08:18 AM
Re: finding out if pointer to memory is valid Ron Natalie C++ 0 06-27-2003 03:36 PM
Re: finding out if pointer to memory is valid Dhruv C++ 0 06-27-2003 01:29 PM
Re: finding out if pointer to memory is valid Alexander Terekhov C++ 0 06-27-2003 11:48 AM
Re: finding out if pointer to memory is valid Sin C++ 1 06-26-2003 09:56 PM



Advertisments