All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Howells <dhowells@redhat.com>
To: torvalds@osdl.org, akpm@osdl.org, kwc@citi.umich.edu
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] Make keyctl(KEYCTL_JOIN_SESSION_KEYRING) use the correct arg
Date: Fri, 25 Feb 2005 11:36:42 +0000	[thread overview]
Message-ID: <15706.1109331402@redhat.com> (raw)
In-Reply-To: <20050225015755.14B611BAA9@citi.umich.edu>


The attached patch makes keyctl() use the correct argument when invoking the
KEYCTL_JOIN_SESSION_KEYRING function.

I'm not sure how this evaded testing before, but I suspect the compiler was
kind and made both argument registers hold the same value.

Thanks to Kevin Coffman <kwc@citi.umich.edu> for spotting this.

Signed-Off-By: David Howells <dhowells@redhat.com>
---
warthog>diffstat -p1 keys-joinsess-2611rc4.diff 
 security/keys/compat.c |    2 +-
 security/keys/keyctl.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff -uNr linux-2.6.11-rc4/security/keys/compat.c linux-2.6.11-rc4-keys-task/security/keys/compat.c
--- linux-2.6.11-rc4/security/keys/compat.c	2005-01-04 11:14:01.000000000 +0000
+++ linux-2.6.11-rc4-keys-task/security/keys/compat.c	2005-02-25 11:02:33.853339509 +0000
@@ -31,7 +31,7 @@
 		return keyctl_get_keyring_ID(arg2, arg3);
 
 	case KEYCTL_JOIN_SESSION_KEYRING:
-		return keyctl_join_session_keyring(compat_ptr(arg3));
+		return keyctl_join_session_keyring(compat_ptr(arg2));
 
 	case KEYCTL_UPDATE:
 		return keyctl_update_key(arg2, compat_ptr(arg3), arg4);
diff -uNr linux-2.6.11-rc4/security/keys/keyctl.c linux-2.6.11-rc4-keys-task/security/keys/keyctl.c
--- linux-2.6.11-rc4/security/keys/keyctl.c	2005-01-04 11:14:01.000000000 +0000
+++ linux-2.6.11-rc4-keys-task/security/keys/keyctl.c	2005-02-25 11:02:24.134152856 +0000
@@ -923,7 +923,7 @@
 					     (int) arg3);
 
 	case KEYCTL_JOIN_SESSION_KEYRING:
-		return keyctl_join_session_keyring((const char __user *) arg3);
+		return keyctl_join_session_keyring((const char __user *) arg2);
 
 	case KEYCTL_UPDATE:
 		return keyctl_update_key((key_serial_t) arg2,

           reply	other threads:[~2005-02-25 11:36 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <20050225015755.14B611BAA9@citi.umich.edu>]

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=15706.1109331402@redhat.com \
    --to=dhowells@redhat.com \
    --cc=akpm@osdl.org \
    --cc=kwc@citi.umich.edu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.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.