Check for NULL pointer in 'ai_canonname'.