qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Luiz Capitulino <lcapitulino@redhat.com>
To: Kusanagi Kouichi <slash@ac.auone-net.jp>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] monitor: Ignore "." and ".." when completing file name.
Date: Wed, 20 Oct 2010 14:58:11 -0200	[thread overview]
Message-ID: <20101020145811.2c5b9616@doriath> (raw)
In-Reply-To: <20101020090002.59B583E403B@msa101.auone-net.jp>

On Wed, 20 Oct 2010 18:00:01 +0900
Kusanagi Kouichi <slash@ac.auone-net.jp> wrote:

> 
> Signed-off-by: Kusanagi Kouichi <slash@ac.auone-net.jp>

Applied to the Monitor queue, thanks.

> ---
>  monitor.c |    5 +++++
>  1 files changed, 5 insertions(+), 0 deletions(-)
> 
> diff --git a/monitor.c b/monitor.c
> index 260cc02..61607c5 100644
> --- a/monitor.c
> +++ b/monitor.c
> @@ -3976,6 +3976,11 @@ static void file_completion(const char *input)
>          d = readdir(ffs);
>          if (!d)
>              break;
> +
> +        if (strcmp(d->d_name, ".") == 0 || strcmp(d->d_name, "..") == 0) {
> +            continue;
> +        }
> +
>          if (strstart(d->d_name, file_prefix, NULL)) {
>              memcpy(file, input, input_path_len);
>              if (input_path_len < sizeof(file))

      reply	other threads:[~2010-10-20 18:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-20  9:00 [Qemu-devel] [PATCH] monitor: Ignore "." and ".." when completing file name Kusanagi Kouichi
2010-10-20 16:58 ` Luiz Capitulino [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=20101020145811.2c5b9616@doriath \
    --to=lcapitulino@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=slash@ac.auone-net.jp \
    /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 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 NNTP newsgroup(s).