public inbox for passt-dev@passt.top
 help / color / mirror / code / Atom feed
From: David Gibson <david@gibson.dropbear.id.au>
To: Stefano Brivio <sbrivio@redhat.com>
Cc: Laurent Vivier <lvivier@redhat.com>, passt-dev@passt.top
Subject: Re: [PATCH] flow: close socket fd on error
Date: Wed, 14 May 2025 16:05:30 +1000	[thread overview]
Message-ID: <aCQyqrcVB1i_66DR@zatzit> (raw)
In-Reply-To: <20250512232050.1e54e0da@elisabeth>

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

On Mon, May 12, 2025 at 11:20:50PM +0200, Stefano Brivio wrote:
> On Mon, 12 May 2025 18:47:00 +0200
> Laurent Vivier <lvivier@redhat.com> wrote:
> 
> > In eea8a76caf85 ("flow: fix podman issue #26073"), we unregister
> > the fd from epoll_ctl() in case of error, but we also need to close it.
> > 
> > As flowside_sock_l4() also calls sock_l4_sa() via flowside_sock_splice()
> > we can do it unconditionally.
> 
> The previous PIF_HOST check made sense to me because it excluded
> PIF_TAP, not so much because it excluded PIF_SPLICE.

Right.  pif_is_socket() exists for exactly that case..

> But anyway, we'll never reach here with anything that's not PIF_HOST
> nor PIF_TAP (kind of by definition), and a spurious epoll_del() is
> surely better than the alternative in any case...

..but in this case it's not relevant because you have to already have
a socket by this point.

> 
> > Fixes: eea8a76caf85 ("flow: fix podman issue #26073")
> > Signed-off-by: Laurent Vivier <lvivier@redhat.com>
> 
> Applied, thanks. New release coming soon.
> 

-- 
David Gibson (he or they)	| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you, not the other way
				| around.
http://www.ozlabs.org/~dgibson

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

      reply	other threads:[~2025-05-14  6:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-12 16:47 [PATCH] flow: close socket fd on error Laurent Vivier
2025-05-12 21:20 ` Stefano Brivio
2025-05-14  6:05   ` David Gibson [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=aCQyqrcVB1i_66DR@zatzit \
    --to=david@gibson.dropbear.id.au \
    --cc=lvivier@redhat.com \
    --cc=passt-dev@passt.top \
    --cc=sbrivio@redhat.com \
    /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.
Code repositories for project(s) associated with this public inbox

	https://passt.top/passt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for IMAP folder(s).