Guard against null messages.