mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Oleg Nesterov <oleg@redhat.com>
To: Denys Vlasenko <dvlasenk@redhat.com>
Cc: Tejun Heo <tj@kernel.org>,
	linux-kernel@vger.kernel.org,
	Denys Vlasenko <vda.linux@googlemail.com>
Subject: Re: [PATCH v3] Simplify PTRACE_foo constants and PTRACE_SETOPTIONS code
Date: Thu, 8 Sep 2011 20:42:15 +0200	[thread overview]
Message-ID: <20110908184215.GA29439@redhat.com> (raw)
In-Reply-To: <1315495101.18043.1.camel@dhcp-25-63.brq.redhat.com>

On 09/08, Denys Vlasenko wrote:
>
>  static int ptrace_setoptions(struct task_struct *child, unsigned long data)
>  {
> ...
> +       if (data & ~(unsigned long)PTRACE_O_MASK) {
> +               child->ptrace &= ~PT_TRACE_MASK; /* historical bug */
> +               return -EINVAL;
> +       }

This is not right. You shouldn't simply return with -EINVAL, this change
adds another bug.  Note that the cuurrent code sets the new bits even if
it returns -EINVAL.

Oleg.


      reply	other threads:[~2011-09-08 23:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-08 15:18 Denys Vlasenko
2011-09-08 18:42 ` Oleg Nesterov [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=20110908184215.GA29439@redhat.com \
    --to=oleg@redhat.com \
    --cc=dvlasenk@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tj@kernel.org \
    --cc=vda.linux@googlemail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome