All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Tokarev <mjt@tls.msk.ru>
To: arei.gonglei@huawei.com, qemu-devel@nongnu.org
Cc: qemu-trivial@nongnu.org, peter.huangpeng@huawei.com, stefanha@redhat.com
Subject: Re: [Qemu-trivial] [PATCH 1/2] tap: remove close(fd)
Date: Sun, 02 Nov 2014 08:06:00 +0300	[thread overview]
Message-ID: <5455BBB8.5040205@msgid.tls.msk.ru> (raw)
In-Reply-To: <1414735861-1232-2-git-send-email-arei.gonglei@huawei.com>

31.10.2014 09:11, arei.gonglei@huawei.com wrote:
> From: Gonglei <arei.gonglei@huawei.com>
> 
> commit 5193e5fb (tap: factor out common tap initialization)
> introduce net_init_tap_one(). But it's inapposite that close
> fd in net_init_tap_one(), we should lay it in the caller,
> becuase some caller needn't to close it if we get the fd
> by monitor_handle_fd_param().
> 
> On the other hand, in other exceptional branch fd doesn't
> be closed, so that's incomplete.

Applied to -trivial, with grammar tweaking in commit message
and with slightly better (in my opinion) subject, like this:

    tap: do not close(fd) in net_init_tap_one()

    commit 5193e5fb (tap: factor out common tap initialization)
    introduce net_init_tap_one(). But it's inappropriate that
    we close fd in net_init_tap_one(), we should lay it in the
    caller, becuase some callers needn't to close it if we get
    the fd by monitor_handle_fd_param().

    On the other hand, in other exceptional branches fd isn't
    closed, so that's incomplete anyway.

Thanks,

/mjt


WARNING: multiple messages have this Message-ID (diff)
From: Michael Tokarev <mjt@tls.msk.ru>
To: arei.gonglei@huawei.com, qemu-devel@nongnu.org
Cc: qemu-trivial@nongnu.org, peter.huangpeng@huawei.com, stefanha@redhat.com
Subject: Re: [Qemu-devel] [Qemu-trivial] [PATCH 1/2] tap: remove close(fd)
Date: Sun, 02 Nov 2014 08:06:00 +0300	[thread overview]
Message-ID: <5455BBB8.5040205@msgid.tls.msk.ru> (raw)
In-Reply-To: <1414735861-1232-2-git-send-email-arei.gonglei@huawei.com>

31.10.2014 09:11, arei.gonglei@huawei.com wrote:
> From: Gonglei <arei.gonglei@huawei.com>
> 
> commit 5193e5fb (tap: factor out common tap initialization)
> introduce net_init_tap_one(). But it's inapposite that close
> fd in net_init_tap_one(), we should lay it in the caller,
> becuase some caller needn't to close it if we get the fd
> by monitor_handle_fd_param().
> 
> On the other hand, in other exceptional branch fd doesn't
> be closed, so that's incomplete.

Applied to -trivial, with grammar tweaking in commit message
and with slightly better (in my opinion) subject, like this:

    tap: do not close(fd) in net_init_tap_one()

    commit 5193e5fb (tap: factor out common tap initialization)
    introduce net_init_tap_one(). But it's inappropriate that
    we close fd in net_init_tap_one(), we should lay it in the
    caller, becuase some callers needn't to close it if we get
    the fd by monitor_handle_fd_param().

    On the other hand, in other exceptional branches fd isn't
    closed, so that's incomplete anyway.

Thanks,

/mjt

  reply	other threads:[~2014-11-02  5:06 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-31  6:10 [Qemu-trivial] [PATCH 0/2] tap: add cleanup logic avoiding leaking fd arei.gonglei
2014-10-31  6:10 ` [Qemu-devel] " arei.gonglei
2014-10-31  6:11 ` [Qemu-trivial] [PATCH 1/2] tap: remove close(fd) arei.gonglei
2014-10-31  6:11   ` [Qemu-devel] " arei.gonglei
2014-11-02  5:06   ` Michael Tokarev [this message]
2014-11-02  5:06     ` [Qemu-devel] [Qemu-trivial] " Michael Tokarev
2014-11-02  5:09     ` Gonglei
2014-11-02  5:09       ` [Qemu-devel] " Gonglei
2014-10-31  6:11 ` [Qemu-trivial] [PATCH 2/2] tap: fix possible fd leak arei.gonglei
2014-10-31  6:11   ` [Qemu-devel] " arei.gonglei
2014-11-02  5:11   ` [Qemu-trivial] " Michael Tokarev
2014-11-02  5:11     ` [Qemu-devel] " Michael Tokarev
2014-11-02  5:21     ` Gonglei
2014-11-02  5:21       ` [Qemu-devel] " Gonglei
2014-11-02  5:24       ` Michael Tokarev
2014-11-02  5:24         ` [Qemu-devel] " Michael Tokarev

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=5455BBB8.5040205@msgid.tls.msk.ru \
    --to=mjt@tls.msk.ru \
    --cc=arei.gonglei@huawei.com \
    --cc=peter.huangpeng@huawei.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@nongnu.org \
    --cc=stefanha@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.
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.