Message ID | 1400015466-16048-1-git-send-email-ncmike@ncultra.org |
---|---|
State | New |
Headers | show |
On 05/13/2014 03:11 PM, Mike Day wrote: Subject line could have used a [PATCHv2] designation to make it obvious this is a fixed version. But that doesn't affect what goes into git. > g_sequence_lookup is not supported by glib < 2.28. The usage > of g_sequence_lookup is not essential in this context (it's a > safeguard against duplicate values in the help message). > Removing the call enables the build on all platforms and > does not change the operation of the help function. > > Signed-off-by: Mike Day <ncmike@ncultra.org> > --- > qemu-img.c | 7 ++----- > 1 file changed, 2 insertions(+), 5 deletions(-) Reviewed-by: Eric Blake <eblake@redhat.com>
On Tue, 13 May 2014 17:11:06 -0400 Mike Day <ncmike@ncultra.org> wrote: > g_sequence_lookup is not supported by glib < 2.28. The usage > of g_sequence_lookup is not essential in this context (it's a > safeguard against duplicate values in the help message). > Removing the call enables the build on all platforms and > does not change the operation of the help function. > > Signed-off-by: Mike Day <ncmike@ncultra.org> > --- > qemu-img.c | 7 ++----- > 1 file changed, 2 insertions(+), 5 deletions(-) I don't get duplicates even without the safeguard :) Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Am 13.05.2014 um 23:48 hat Eric Blake geschrieben: > On 05/13/2014 03:11 PM, Mike Day wrote: > > Subject line could have used a [PATCHv2] designation to make it obvious > this is a fixed version. But that doesn't affect what goes into git. > > > g_sequence_lookup is not supported by glib < 2.28. The usage > > of g_sequence_lookup is not essential in this context (it's a > > safeguard against duplicate values in the help message). > > Removing the call enables the build on all platforms and > > does not change the operation of the help function. > > > > Signed-off-by: Mike Day <ncmike@ncultra.org> > > --- > > qemu-img.c | 7 ++----- > > 1 file changed, 2 insertions(+), 5 deletions(-) > > Reviewed-by: Eric Blake <eblake@redhat.com> Thanks, applied to the block branch. Kevin
On 14 May 2014 08:44, Kevin Wolf <kwolf@redhat.com> wrote: > Am 13.05.2014 um 23:48 hat Eric Blake geschrieben: >> On 05/13/2014 03:11 PM, Mike Day wrote: >> >> Subject line could have used a [PATCHv2] designation to make it obvious >> this is a fixed version. But that doesn't affect what goes into git. >> >> > g_sequence_lookup is not supported by glib < 2.28. The usage >> > of g_sequence_lookup is not essential in this context (it's a >> > safeguard against duplicate values in the help message). >> > Removing the call enables the build on all platforms and >> > does not change the operation of the help function. >> > >> > Signed-off-by: Mike Day <ncmike@ncultra.org> >> > --- >> > qemu-img.c | 7 ++----- >> > 1 file changed, 2 insertions(+), 5 deletions(-) >> >> Reviewed-by: Eric Blake <eblake@redhat.com> > > Thanks, applied to the block branch. Ah, I was thinking about applying this directly since it's a build fix. But I guess it could go through the block branch instead... thanks -- PMM
On 14.05.14 10:23, Peter Maydell wrote: > On 14 May 2014 08:44, Kevin Wolf <kwolf@redhat.com> wrote: >> Am 13.05.2014 um 23:48 hat Eric Blake geschrieben: >>> On 05/13/2014 03:11 PM, Mike Day wrote: >>> >>> Subject line could have used a [PATCHv2] designation to make it obvious >>> this is a fixed version. But that doesn't affect what goes into git. >>> >>>> g_sequence_lookup is not supported by glib < 2.28. The usage >>>> of g_sequence_lookup is not essential in this context (it's a >>>> safeguard against duplicate values in the help message). >>>> Removing the call enables the build on all platforms and >>>> does not change the operation of the help function. >>>> >>>> Signed-off-by: Mike Day <ncmike@ncultra.org> >>>> --- >>>> qemu-img.c | 7 ++----- >>>> 1 file changed, 2 insertions(+), 5 deletions(-) >>> Reviewed-by: Eric Blake <eblake@redhat.com> >> Thanks, applied to the block branch. > Ah, I was thinking about applying this directly since it's a build fix. > But I guess it could go through the block branch instead... Yes, could you please apply it directly? Alex
diff --git a/qemu-img.c b/qemu-img.c index 04ce02a..1ad899e 100644 --- a/qemu-img.c +++ b/qemu-img.c @@ -70,11 +70,8 @@ static void add_format_to_seq(void *opaque, const char *fmt_name) { GSequence *seq = opaque; - if (!g_sequence_lookup(seq, (gpointer)fmt_name, - compare_data, NULL)) { - g_sequence_insert_sorted(seq, (gpointer)fmt_name, - compare_data, NULL); - } + g_sequence_insert_sorted(seq, (gpointer)fmt_name, + compare_data, NULL); } static void QEMU_NORETURN GCC_FMT_ATTR(1, 2) error_exit(const char *fmt, ...)
g_sequence_lookup is not supported by glib < 2.28. The usage of g_sequence_lookup is not essential in this context (it's a safeguard against duplicate values in the help message). Removing the call enables the build on all platforms and does not change the operation of the help function. Signed-off-by: Mike Day <ncmike@ncultra.org> --- qemu-img.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)