How to validate LPVOID to <Bad Ptr>
<p>I'm working with C++ unmanaged, the problem that I have happens when I call a method that returns an LPVOID.</p>

<pre><code>LPVOID MyMethod(...);
</code></pre>

<p>The problem is that this method sometimes returns a Bad Ptr and I want to know if there is a way of detecting this, if the value returned is a Bad Ptr.</p>

<p>I have tried asking if it is NULL with no luck.</p>

<p>The only way in which I realize if the result is a Bad Ptr is while I'm debugging, I have tried some different ways but still unable to do it.</p>
