util: use quoted word parsing where applicable
diff --git a/src/load-fragment.c b/src/load-fragment.c
index 1cc7c5c..43b8093 100644
--- a/src/load-fragment.c
+++ b/src/load-fragment.c
@@ -61,7 +61,7 @@
assert(lvalue);
assert(rvalue);
- FOREACH_WORD(w, l, rvalue, state) {
+ FOREACH_WORD_QUOTED(w, l, rvalue, state) {
char *t, *k;
int r;
@@ -103,7 +103,7 @@
assert(rvalue);
assert(data);
- FOREACH_WORD(w, l, rvalue, state) {
+ FOREACH_WORD_QUOTED(w, l, rvalue, state) {
char *t, *k;
int r;
@@ -689,7 +689,7 @@
assert(rvalue);
assert(data);
- FOREACH_WORD(w, l, rvalue, state) {
+ FOREACH_WORD_QUOTED(w, l, rvalue, state) {
char *t;
int r;
unsigned cpu;
@@ -766,7 +766,7 @@
assert(rvalue);
assert(data);
- FOREACH_WORD(w, l, rvalue, state) {
+ FOREACH_WORD_QUOTED(w, l, rvalue, state) {
if (first_word(w, "keep-caps"))
c->secure_bits |= SECURE_KEEP_CAPS;
else if (first_word(w, "keep-caps-locked"))
@@ -807,7 +807,7 @@
assert(rvalue);
assert(data);
- FOREACH_WORD(w, l, rvalue, state) {
+ FOREACH_WORD_QUOTED(w, l, rvalue, state) {
char *t;
int r;
cap_value_t cap;
@@ -902,11 +902,11 @@
size_t l;
char *state;
- FOREACH_WORD(w, l, rvalue, state) {
+ FOREACH_WORD_QUOTED(w, l, rvalue, state) {
char *t;
int r;
- if (!(t = strndup(w, l)))
+ if (!(t = cunescape_length(w, l)))
return -ENOMEM;
r = unit_add_cgroup_from_text(u, t);
@@ -967,7 +967,7 @@
assert(rvalue);
assert(data);
- FOREACH_WORD(w, l, rvalue, state) {
+ FOREACH_WORD_QUOTED(w, l, rvalue, state) {
if (strncmp(w, "shared", l) == 0)
flags |= MS_SHARED;
else if (strncmp(w, "slave", l) == 0)