summaryrefslogtreecommitdiff
path: root/src/import/importd.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/import/importd.c')
-rw-r--r--src/import/importd.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/import/importd.c b/src/import/importd.c
index ed757019cf..4675aa5a61 100644
--- a/src/import/importd.c
+++ b/src/import/importd.c
@@ -590,14 +590,9 @@ static int manager_on_notify(sd_event_source *s, int fd, uint32_t revents, void
buf[n] = 0;
- p = startswith(buf, "X_IMPORT_PROGRESS=");
- if (!p) {
- p = strstr(buf, "\nX_IMPORT_PROGRESS=");
- if (!p)
- return 0;
-
- p += 19;
- }
+ p = find_line_startswith(buf, "X_IMPORT_PROGRESS=");
+ if (!p)
+ return 0;
e = strchrnul(p, '\n');
*e = 0;