diff --git a/lib/perfdata/gelfwriter.cpp b/lib/perfdata/gelfwriter.cpp index 32a1e2fed..94abac435 100644 --- a/lib/perfdata/gelfwriter.cpp +++ b/lib/perfdata/gelfwriter.cpp @@ -148,7 +148,7 @@ void GelfWriter::NotificationToUserHandler(const Notification::Ptr& notification fields->Set("short_message", output); } else { fields->Set("_type", "HOST NOTIFICATION"); - fields->Set("short_message", "(" << (host->IsReachable() ? Host::StateToString(host->GetState()) : "UNREACHABLE") << ")"); + fields->Set("short_message", "(" + (host->IsReachable() ? Host::StateToString(host->GetState()) : String("UNREACHABLE")) + ")"); } fields->Set("_state", service ? Service::StateToString(service->GetState()) : Host::StateToString(host->GetState()));