Re: [PATCH v4 1/9] qapi: Make qapi_bool_parse() gracefully handle NULL value

2025-01-10 Thread Daniel P . Berrangé
On Fri, Jan 10, 2025 at 02:03:09PM +0100, Ilya Leoshkevich wrote: > On Fri, 2025-01-10 at 11:33 +, Daniel P. Berrangé wrote: > > On Wed, Jan 08, 2025 at 09:04:56PM +0100, Ilya Leoshkevich wrote: > > > Use g_strcmp0(), so that NULL is considered an invalid parameter > > > value. > > > > Why are

Re: [PATCH v4 1/9] qapi: Make qapi_bool_parse() gracefully handle NULL value

2025-01-10 Thread Ilya Leoshkevich
On Fri, 2025-01-10 at 11:33 +, Daniel P. Berrangé wrote: > On Wed, Jan 08, 2025 at 09:04:56PM +0100, Ilya Leoshkevich wrote: > > Use g_strcmp0(), so that NULL is considered an invalid parameter > > value. > > Why are we calling qapi_bool_parse with a NULL value in the first > place ? IMHO this

Re: [PATCH v4 1/9] qapi: Make qapi_bool_parse() gracefully handle NULL value

2025-01-10 Thread Daniel P . Berrangé
On Wed, Jan 08, 2025 at 09:04:56PM +0100, Ilya Leoshkevich wrote: > Use g_strcmp0(), so that NULL is considered an invalid parameter value. Why are we calling qapi_bool_parse with a NULL value in the first place ? IMHO this is a sign of a bug higher up the call chain that ought to be fixed, as in