[SVN r49549]
Also port some "glaringly obvious" bugfixes from HEAD. Hope it doesn't cause problems. [SVN r35237]
always return a pointer that holds the owning python object *unless* the python object contains a NULL shared_ptr holder of the right type. [SVN r28947]