summaryrefslogtreecommitdiff
path: root/src/libsystemd
diff options
context:
space:
mode:
Diffstat (limited to 'src/libsystemd')
-rw-r--r--src/libsystemd/sd-device/device-enumerator.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/libsystemd/sd-device/device-enumerator.c b/src/libsystemd/sd-device/device-enumerator.c
index 0bd2c89eb6..f3f59e2ac3 100644
--- a/src/libsystemd/sd-device/device-enumerator.c
+++ b/src/libsystemd/sd-device/device-enumerator.c
@@ -281,11 +281,10 @@ static int sound_device_compare(const char *devpath_a, const char *devpath_b) {
* kernel makes this guarantee when creating those devices, and hence we should too when
* enumerating them. */
- sound_a = strstr(devpath_a, "/sound/card");
+ sound_a = strstrafter(devpath_a, "/sound/card");
if (!sound_a)
return 0;
- sound_a += STRLEN("/sound/card");
sound_a = strchr(devpath_a, '/');
if (!sound_a)
return 0;