[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 09/13] block/gluster: Use URI parsing code from glib
From: |
Eric Blake |
Subject: |
Re: [PATCH v2 09/13] block/gluster: Use URI parsing code from glib |
Date: |
Fri, 12 Apr 2024 09:43:48 -0500 |
User-agent: |
NeoMutt/20240201 |
On Fri, Apr 12, 2024 at 09:40:18AM -0500, Eric Blake wrote:
> > @@ -364,57 +363,57 @@ static int
> > qemu_gluster_parse_uri(BlockdevOptionsGluster *gconf,
> > QAPI_LIST_PREPEND(gconf->server, gsconf);
> >
> > /* transport */
> > - if (!uri->scheme || !strcmp(uri->scheme, "gluster")) {
> > + uri_scheme = g_uri_get_scheme(uri);
> > + if (!uri_scheme || !strcmp(uri_scheme, "gluster")) {
>
> Pre-existing, but per RFC 3986, we should probably be using strcasecmp
> for scheme comparisons (I'm not sure if g_uri_parse guarantees a
> lower-case return, even when the user passed in upper case). That can
> be a separate patch.
Even beter, g_ascii_strcasecmp() (since strcasecmp can be
locale-specific which is generally not what we need here)
--
Eric Blake, Principal Software Engineer
Red Hat, Inc.
Virtualization: qemu.org | libguestfs.org
- [PATCH v2 06/13] ci: move external build environment setups to CentOS Stream 9, (continued)
- [PATCH v2 06/13] ci: move external build environment setups to CentOS Stream 9, Thomas Huth, 2024/04/12
- [PATCH v2 07/13] Bump minimum glib version to v2.66, Thomas Huth, 2024/04/12
- [PATCH v2 08/13] Remove glib compatibility code that is not required anymore, Thomas Huth, 2024/04/12
- [PATCH v2 10/13] block/nbd: Use URI parsing code from glib, Thomas Huth, 2024/04/12
- [PATCH v2 09/13] block/gluster: Use URI parsing code from glib, Thomas Huth, 2024/04/12
- [PATCH v2 12/13] block/ssh: Use URI parsing code from glib, Thomas Huth, 2024/04/12
- [PATCH v2 11/13] block/nfs: Use URI parsing code from glib, Thomas Huth, 2024/04/12
- [PATCH v2 13/13] util/uri: Remove the old URI parsing code, Thomas Huth, 2024/04/12