Can anyone explain to me why this code generates a Privilage violation when
executing the new operator?
#include <Pilot.h>
#include <new>
void Foo ();
class Bar
{
public:
Bar () : mValue (0) {}
private:
long mValue;
};
void Foo ()
{
Bar **b = (Bar**)::MemHandleNew(sizeof(Bar));
::MemHandleLock((VoidHand)b);
::new(*b) Bar;
::MemHandleUnlock((VoidHand)b);
}
I really thought this was valid code...
-maarten
--
Maarten L. Hekkelman http://www.hekkelman.com
Hekkelman Programmatuur bv mailto:maarten at hekkelman.com