Clear entries referencing the domain in reference_queue_clear_for_domain () even if the object is already null. Fixes #4595.