All of lore.kernel.org
 help / color / mirror / Atom feed
From: Denis Kenzior <denkenz@gmail.com>
To: iwd@lists.01.org
Subject: Re: [PATCH] network: use L_AUTO_FREE_VAR
Date: Mon, 17 May 2021 10:45:42 -0500	[thread overview]
Message-ID: <88936927-ab39-6063-834b-8edbd89a2d33@gmail.com> (raw)
In-Reply-To: <20210514163640.305070-1-Marc-Antoine@Perennou.com>

[-- Attachment #1: Type: text/plain, Size: 1186 bytes --]

Hi Marc-Antoine,

On 5/14/21 11:36 AM, Marc-Antoine Perennou wrote:
> Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
> ---
>   src/network.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/src/network.c b/src/network.c
> index 9e858663..0eb3687e 100644
> --- a/src/network.c
> +++ b/src/network.c
> @@ -380,10 +380,10 @@ static int network_load_psk(struct network *network, bool need_passphrase)
>   	size_t psk_len;
>   	uint8_t *psk = l_settings_get_bytes(network->settings, "Security",
>   						"PreSharedKey", &psk_len);
> -	_auto_(l_free) char *passphrase =
> +	L_AUTO_FREE_VAR(char *, passphrase) =
>   			l_settings_get_string(network->settings,
>   						"Security", "Passphrase");
> -	_auto_(l_free) char *path =
> +	L_AUTO_FREE_VAR(char *, path) =
>   		storage_get_network_file_path(security, ssid);
>   	int r;
>   
> 

Was this supposed to be part of a different set?  Can you resend the entire 
series, it isn't quite clear to me where you're going with this?

I would guess your intent is to use _auto_ with destructors only and fall back 
to L_AUTO_FREE_VAR for l_free?

Regards,
-Denis

      reply	other threads:[~2021-05-17 15:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-14 16:36 [PATCH] network: use L_AUTO_FREE_VAR Marc-Antoine Perennou
2021-05-17 15:45 ` Denis Kenzior [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=88936927-ab39-6063-834b-8edbd89a2d33@gmail.com \
    --to=denkenz@gmail.com \
    --cc=iwd@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.