what's the reason for this check (scoped_ptr<ResourceHost>() is returned anyway) ?