search for: extract_optionally_quot

Displaying 4 results from an estimated 4 matches for "extract_optionally_quot".

2014 Feb 04
2
Re: [PATCH 2/3] New API: part-get-name (RHBZ#593511).
On Tue, Feb 04, 2014 at 04:01:32PM +0100, Pino Toscano wrote: > +static char * > +extract_optionally_quoted (const char *value) > +{ > + size_t value_len = strlen (value); > + > + if (value_len >= 2 && > + ((value[0] == '\'' && value[value_len - 1] == '\'') || > + (value[0] == '"' && value[value_len - 1] == &...
2014 Feb 04
0
[PATCH 2/3] New API: part-get-name (RHBZ#593511).
...+++++++ src/MAX_PROC_NR | 2 +- 3 files changed, 47 insertions(+), 1 deletion(-) diff --git a/daemon/parted.c b/daemon/parted.c index 5282adb..83f2411 100644 --- a/daemon/parted.c +++ b/daemon/parted.c @@ -886,9 +886,42 @@ extract_uuid (const char *value) return ret; } +static char * +extract_optionally_quoted (const char *value) +{ + size_t value_len = strlen (value); + + if (value_len >= 2 && + ((value[0] == '\'' && value[value_len - 1] == '\'') || + (value[0] == '"' && value[value_len - 1] == '"'))) { + valu...
2014 Feb 04
6
[PATCH 0/3] virt-resize: preserve GPT partitions label
Hi, attached there are few patches to implement a way to get the label of GPT partitions (refactoring an existing function and adding a new daemon API) and using it in virt-resize to restore them when copying partitions. Thanks, Pino Toscano (3): daemon: parted: refactor sgdisk info parsing code New API: part-get-name (RHBZ#593511). resize: preserve GPT partition names (RHBZ#1060404).
2014 Feb 04
0
Re: [PATCH 2/3] New API: part-get-name (RHBZ#593511).
On Tuesday 04 February 2014 15:59:36 Richard W.M. Jones wrote: > On Tue, Feb 04, 2014 at 04:01:32PM +0100, Pino Toscano wrote: > > +static char * > > +extract_optionally_quoted (const char *value) > > +{ > > + size_t value_len = strlen (value); > > + > > + if (value_len >= 2 && > > + ((value[0] == '\'' && value[value_len - 1] == '\'') || > > + (value[0] == '"' &&...