Re: Is operator new safe?
Re: Is operator new safe?
- Subject: Re: Is operator new safe?
- From: "William Kucharski" <email@hidden>
- Date: Tue, 22 Apr 2003 02:31:04 -0600
>
Is it safe to use the c++ operator new in a kernel extension?
>
>
I'm porting a file system library written in c++ to MacOS X, and I'm
>
getting a kernel panic when it calls new after performing a series of
>
I/Os, so I'm trying to determine whether the call to new is the
>
problem, or if I trashed memory when performing my I/O.
The IOKIT kexts use "new" all over the place without any issues.
Just make sure to check the value you get back to see if the "new" returned
a valid pointer. If you're already doing that and still panic then something
is corrupting your pointers somehow.
William Kucharski
email@hidden
_______________________________________________
darwin-kernel mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/darwin-kernel
Do not post admin requests to the list. They will be ignored.