path: follow symbolic link for parent path (2)

c0e57ba9e22ee937722958d8b912ade2a37f206d fixed the fallback path.
We should do the same for name_to_handle_at().

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
path: make the check for unsupported name_to_handle_at symmetric

If child supports, but the parent does not, or when the child does
not support, but the parent does, assume the child is a mount point.

Only if neither supports use the fallback.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
path-util: fix breakage in path_is_mount_point

This fixes 2 problems introduced by 6feeeab0bc:

1) If name_to_handle_at returns ENOSYS for the child, we'll wrongly
return -ENOSYS when it returns the same for the parent. Immediately
jump to the fallback logic when we get ENOSYS.

2) If name_to_handle_at returns EOPNOTSUPP for the child but suceeds
for the parent, we'll be comparing an uninitialized value (mount_id) to
an initialized value (mount_id_parent). Initialize the mount_id
variables to invalid mount_ids to avoid this.

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Treat a trailing backslash as an error

Commit a2a5291b3f5 changed the parser to reject unfinished quoted
strings. Unfortunately it introduced an error where a trailing
backslash would case an infinite loop. Of course this must fixed, but
the question is what to to instead. Allowing trailing backslashes and
treating them as normal characters would be one option, but this seems
suboptimal. First, there would be inconsistency between handling of
quoting and of backslashes. Second, a trailing backslash is most
likely an error, at it seems better to point it out to the user than
to try to continue.

Updated rules:
ExecStart=/bin/echo \\ → OK, prints a backslash
ExecStart=/bin/echo \ → error
ExecStart=/bin/echo "x → error
ExecStart=/bin/echo "x"y → error

Signed-off-by: Anthony G. Basile <blueness@gentoo.org>