From 78df02dba61d4d9e4f89225ddf69d5cfcdc9d184 Mon Sep 17 00:00:00 2001 From: Tanu Kaskinen Date: Tue, 22 Jan 2013 08:48:02 +0200 Subject: [PATCH] device-port: Return early from pa_device_port_set_latency_offset() if the offset doesn't change. This avoids sending change notifications when nothing changes. --- src/pulsecore/device-port.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/pulsecore/device-port.c b/src/pulsecore/device-port.c index fa78e08b4..6d787aca2 100644 --- a/src/pulsecore/device-port.c +++ b/src/pulsecore/device-port.c @@ -104,6 +104,9 @@ void pa_device_port_set_latency_offset(pa_device_port *p, int64_t offset) { pa_assert(p); + if (offset == p->latency_offset) + return; + p->latency_offset = offset; if (p->is_output) {