Re: [PATCH 4/4] src: Use g_steal_pointer() more

2022-02-01 Thread Michal Prívozník
On 2/1/22 17:59, Erik Skultety wrote: > On Tue, Feb 01, 2022 at 05:23:52PM +0100, Michal Prívozník wrote: >> On 2/1/22 17:18, Erik Skultety wrote: >>> On Mon, Jan 31, 2022 at 03:53:42PM +0100, Michal Privoznik wrote: There are few places where the g_steal_pointer() is open coded. Switch

Re: [PATCH 4/4] src: Use g_steal_pointer() more

2022-02-01 Thread Erik Skultety
On Tue, Feb 01, 2022 at 05:23:52PM +0100, Michal Prívozník wrote: > On 2/1/22 17:18, Erik Skultety wrote: > > On Mon, Jan 31, 2022 at 03:53:42PM +0100, Michal Privoznik wrote: > >> There are few places where the g_steal_pointer() is open coded. > >> Switch them to calling the g_steal_pointer()

Re: [PATCH 4/4] src: Use g_steal_pointer() more

2022-02-01 Thread Michal Prívozník
On 2/1/22 17:18, Erik Skultety wrote: > On Mon, Jan 31, 2022 at 03:53:42PM +0100, Michal Privoznik wrote: >> There are few places where the g_steal_pointer() is open coded. >> Switch them to calling the g_steal_pointer() function instead. >> Generated by the following spatch: >> >> @ rule1 @ >>

Re: [PATCH 4/4] src: Use g_steal_pointer() more

2022-02-01 Thread Erik Skultety
On Mon, Jan 31, 2022 at 03:53:42PM +0100, Michal Privoznik wrote: > There are few places where the g_steal_pointer() is open coded. > Switch them to calling the g_steal_pointer() function instead. > Generated by the following spatch: > > @ rule1 @ > expression a, b; > @@ > <... > - b

[PATCH 4/4] src: Use g_steal_pointer() more

2022-01-31 Thread Michal Privoznik
There are few places where the g_steal_pointer() is open coded. Switch them to calling the g_steal_pointer() function instead. Generated by the following spatch: @ rule1 @ expression a, b; @@ <... - b = a; ... when != b - a = NULL; + b = g_steal_pointer(); ...>