Skip to content

Commit 9cb8054

Browse files
authored
DPL GUI: do not sent any state when GUI is disabled (#14184)
1 parent efbf147 commit 9cb8054

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Framework/Core/src/CommonServices.cxx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
#include "Framework/DeviceConfig.h"
4545
#include "Framework/DefaultsHelpers.h"
4646
#include "Framework/Signpost.h"
47+
#include "Framework/DriverConfig.h"
4748

4849
#include "TextDriverClient.h"
4950
#include "WSDriverClient.h"
@@ -800,6 +801,9 @@ auto sendRelayerMetrics(ServiceRegistryRef registry, DataProcessingStats& stats)
800801

801802
auto flushStates(ServiceRegistryRef registry, DataProcessingStates& states) -> void
802803
{
804+
if (!registry.get<DriverConfig const>().driverHasGUI) {
805+
return;
806+
}
803807
states.flushChangedStates([&states, registry](std::string const& spec, int64_t timestamp, std::string_view value) mutable -> void {
804808
auto& client = registry.get<ControlService>();
805809
client.push(spec, value, timestamp);

0 commit comments

Comments
 (0)