File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -546,11 +546,13 @@ type systemd_component = {
546
546
# escaped full unitnames are allowed (or use shortnames and type)
547
547
" unit" ? systemd_unit_type{}
548
548
} with {
549
- foreach (name; unit; SELF[" unit" ]) {
550
- if (unit[" type" ] == " mount" && exists (unit[" file" ]) && exists (unit[" file" ][" config" ][" mount" ])) {
551
- goodname = systemd_make_mountunit(unit[" file" ][" config" ][" mount" ][" Where" ]);
552
- if (goodname ! = name) {
553
- error (' Incorrect name for mount unit, the name must match Where: %s vs %s' , name, goodname);
549
+ if (is_defined (SELF[" unit" ])) {
550
+ foreach (name; unit; SELF[" unit" ]) {
551
+ if (unit[" type" ] == " mount" && exists (unit[" file" ]) && exists (unit[" file" ][" config" ][" mount" ])) {
552
+ goodname = systemd_make_mountunit(unit[" file" ][" config" ][" mount" ][" Where" ]);
553
+ if (goodname ! = name) {
554
+ error (' Incorrect name for mount unit, the name must match Where: %s vs %s' , name, goodname);
555
+ };
554
556
};
555
557
};
556
558
};
You can’t perform that action at this time.
0 commit comments