[ofw] NDv2 provider patch

Hefty, Sean sean.hefty at intel.com
Tue Jul 27 09:38:23 PDT 2010


> > auto-reference obscurity...
> 
> Write it correctly once, and you don't have to worry about it further.

You do have to worry about it further.  Someone has to be able to read and understand the code other than the original author.  In fact, making the code readable should be one of the (if not the) primary focus of the code.  That's the first step in making the code maintainable.

I personally hate this auto-ref concept and code that it introduces.  I didn't like it the first time you introduced it, which added 100 or so lines of obscure, complex code to save exactly 1 call to free.  All of the classes have AddRef and Release calls, just use them.

> >> +       static LONG ObjCount(){ return m_nObj; }
> >
> > What is this for?
> 
> DllCanUnloadNow uses it.  If there are any objects, it returns E_FALSE.

Can't we just count process attach/detach?  If that doesn't work, then something seems broken.





More information about the ofw mailing list