Fixed mishandling of negative oid refs