Re: [systemd-devel] [PATCH 1/9] util: Add unescape_first_word()

2015-06-19 Thread Lennart Poettering
On Fri, 19.06.15 10:56, Richard Maw (richard@codethink.co.uk) wrote: > On Thu, Jun 18, 2015 at 08:30:22PM +0200, Lennart Poettering wrote: > > On Thu, 28.05.15 13:02, Richard Maw (richard@codethink.co.uk) wrote: > > > > > This is a superset of the functionality of unquote_first_word, allo

Re: [systemd-devel] [PATCH 1/9] util: Add unescape_first_word()

2015-06-19 Thread Richard Maw
On Thu, Jun 18, 2015 at 08:30:22PM +0200, Lennart Poettering wrote: > On Thu, 28.05.15 13:02, Richard Maw (richard@codethink.co.uk) wrote: > > > This is a superset of the functionality of unquote_first_word, allowing > > non-whitespace separators, and doesn't interpret quotes unless > > UNQUOT

Re: [systemd-devel] [PATCH 1/9] util: Add unescape_first_word()

2015-06-18 Thread Lennart Poettering
On Thu, 28.05.15 13:02, Richard Maw (richard@codethink.co.uk) wrote: > This is a superset of the functionality of unquote_first_word, allowing > non-whitespace separators, and doesn't interpret quotes unless > UNQUOTE_QUOTES is included in flags. Hmm, makes sense, but I'd actually just have o

Re: [systemd-devel] [PATCH 1/9] util: Add unescape_first_word()

2015-05-28 Thread Richard Maw
On Thu, May 28, 2015 at 01:02:07PM +0100, Richard Maw wrote: > diff --git a/src/shared/util.h b/src/shared/util.h > index eb35952..dd86ddc 100644 > --- a/src/shared/util.h > +++ b/src/shared/util.h > @@ -855,10 +855,13 @@ int is_dir(const char *path, bool follow); > int is_device_node(const char *

[systemd-devel] [PATCH 1/9] util: Add unescape_first_word()

2015-05-28 Thread Richard Maw
This is a superset of the functionality of unquote_first_word, allowing non-whitespace separators, and doesn't interpret quotes unless UNQUOTE_QUOTES is included in flags. This also adds UNQUOTE_SEPARATOR_SPLIT, which has it return multiple empty strings when there is a span of separator character