Thanks.
Was it pre-Snow Leopard?
I've just seen this following text from the Kernel release notes for Snow Leopard, would this make a difference? ( I notice it mentions I/O however, why is C++ allowed in I/O kexts but not in others?)
*Mixed C/C++ Kexts*
Mac OS X Snow Leopard features support for kexts that use both C and C++ code. On prior
releases of Mac OS X, making use of Libkern C++ classes in a generic (C-based) kext was a
risky proposition, since the I/O Kit auto-unloading mechanism destroyed any kext
referencing such classes if there were no instances of them. Apart from that, even if non-
Libkern C++ was used, the stub routine invoked at unload called the kext’s static C++
destructors before the kext’s stop routine, and when the kext was auto-unloaded the stop
routine wasn’t invoked at all.
Snow Leopard corrects these issues by:
Marking only kexts that define subclasses of IOService for auto-unload. Non-I/O Kit
kexts loaded on Snow Leopard can safely use and subclass Libkern C++ classes.
Altering the stub unload routine to call the kext’s stop routine first, then the kext’s
static C++ destructors. Important: To gain this behavior you must build your kext to
be targeted against Snow Leopard, as the stub routine is built into the kext.
Always unloading a kext by calling both the stop routine and then the C++ static
destructors, regardless of kext type (generic or I/O Kit).