qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Kirill A. Shutemov" <k.shutemov@gmail.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] qemu/linux-user syscall.c
Date: Sun, 11 Feb 2007 21:33:00 +0300	[thread overview]
Message-ID: <20070211183300.GA3012@localhost.localdomain> (raw)
In-Reply-To: <200702111835.37521.paul@codesourcery.com>


[-- Attachment #1.1: Type: text/plain, Size: 833 bytes --]

On [Sun, 11.02.2007 18:35], Paul Brook wrote:
> On Sunday 11 February 2007 18:26, Thiemo Seufer wrote:
> > CVSROOT:	/sources/qemu
> > Module name:	qemu
> > Changes by:	Thiemo Seufer <ths>	07/02/11 18:26:54
> >
> > Modified files:
> > 	linux-user     : syscall.c
> >
> > Log message:
> > 	Linux userland emulation of syslog, from Debian patchset.
> >
> > CVSWeb URLs:
> > http://cvs.savannah.gnu.org/viewcvs/qemu/linux-user/syscall.c?cvsroot=qemu&
> >r1=1.83&r2=1.84
> 
> >       ret = get_errno(sys_syslog((int)arg1, (char*)arg2, (int)arg3));
> 
> This is wrong. It should use lock_user_string or similar. Please fix or 
> revert.
Patch in the attachment.

Imported only two syscall from Debian patchset. What about others(mount,
mount, uselib, mincore, clock_gettime)? Should I split it in
several patches?

[-- Attachment #1.2: syslog.patch --]
[-- Type: text/plain, Size: 641 bytes --]

Index: linux-user/syscall.c
===================================================================
RCS file: /sources/qemu/qemu/linux-user/syscall.c,v
retrieving revision 1.85
diff -u -r1.85 syscall.c
--- linux-user/syscall.c	11 Feb 2007 18:36:44 -0000	1.85
+++ linux-user/syscall.c	11 Feb 2007 19:23:28 -0000
@@ -2952,7 +2952,9 @@
 #endif
 
     case TARGET_NR_syslog:
-        ret = get_errno(sys_syslog((int)arg1, (char*)arg2, (int)arg3));
+        p = lock_user_string(arg2);
+        ret = get_errno(sys_syslog((int)arg1, p, (int)arg3));
+        unlock_user(p, arg2, 0);
         break;
 
     case TARGET_NR_setitimer:

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

  reply	other threads:[~2007-02-11 19:33 UTC|newest]

Thread overview: 74+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-02-11 18:26 [Qemu-devel] qemu/linux-user syscall.c Thiemo Seufer
2007-02-11 18:35 ` Paul Brook
2007-02-11 18:33   ` Kirill A. Shutemov [this message]
2007-02-11 20:13     ` Thiemo Seufer
  -- strict thread matches above, loose matches on Subject: below --
2008-03-28 22:32 Aurelien Jarno
2008-02-10 13:28 Andrzej Zaborowski
2008-02-04 22:26 Fabrice Bellard
2007-12-18  2:41 Thiemo Seufer
2007-12-18  2:39 Thiemo Seufer
2007-12-09 23:12 Thiemo Seufer
2007-12-09  2:37 Thiemo Seufer
2007-12-09  2:25 Thiemo Seufer
2007-12-02  6:28 Thiemo Seufer
2007-11-11 23:11 Fabrice Bellard
2007-11-11 19:34 Fabrice Bellard
2007-11-11 17:39 Fabrice Bellard
2007-11-11 15:11 Fabrice Bellard
2007-11-11 14:57 Fabrice Bellard
2007-10-30 21:06 Andrzej Zaborowski
2007-10-09  3:42 Thiemo Seufer
2007-09-25 17:50 Thiemo Seufer
2007-09-25 16:09 Thiemo Seufer
2007-09-24  9:27 Thiemo Seufer
2007-09-24  9:26 Thiemo Seufer
2007-09-24  9:26 Thiemo Seufer
2007-09-24  9:25 Thiemo Seufer
2007-09-24  9:25 Thiemo Seufer
2007-09-24  9:24 Thiemo Seufer
2007-09-24  9:24 Thiemo Seufer
2007-09-24  9:23 Thiemo Seufer
2007-09-24  9:23 Thiemo Seufer
2007-09-24  9:22 Thiemo Seufer
2007-09-24  9:21 Thiemo Seufer
2007-09-16 21:39 Thiemo Seufer
2007-07-23 15:37 Thiemo Seufer
2007-07-12 11:06 Thiemo Seufer
2007-07-07 20:45 Blue Swirl
2007-06-03 14:27 Thiemo Seufer
2007-06-01 11:50 Thiemo Seufer
2007-06-01 11:49 Thiemo Seufer
2007-05-28 20:07 Thiemo Seufer
2007-05-28 14:05 Thiemo Seufer
2007-05-28 14:28 ` Paul Brook
2007-05-28 20:08   ` Thiemo Seufer
2007-05-28 20:30   ` Blue Swirl
2007-05-28 21:40     ` Paul Brook
2007-04-26 23:49 Thiemo Seufer
2007-04-01 18:31 Thiemo Seufer
2007-03-31 18:59 Thiemo Seufer
2007-03-22 15:08 Thiemo Seufer
2007-03-20 21:50 Thiemo Seufer
2007-03-19 13:09 Thiemo Seufer
2007-03-19 13:05 Thiemo Seufer
2007-03-17  1:27 Paul Brook
2007-03-19 10:47 ` Kirill A. Shutemov
2007-02-17 22:25 Thiemo Seufer
2007-02-11 20:03 Thiemo Seufer
2007-02-11 18:36 Thiemo Seufer
2007-02-02 22:05 Thiemo Seufer
2007-02-02 22:05 Thiemo Seufer
2007-01-05 20:55 Thiemo Seufer
2006-12-11 22:04 Thiemo Seufer
2006-12-11 19:13 Thiemo Seufer
2006-12-08  1:32 Thiemo Seufer
2006-11-19 15:26 Paul Brook
2006-11-21 13:32 ` Raphaël Rigo
2006-06-14 13:36 Fabrice Bellard
2006-04-16 14:14 Paul Brook
2005-12-18 20:03 Fabrice Bellard
2005-07-23 15:10 Fabrice Bellard
2005-07-23 14:46 Fabrice Bellard
2005-03-01 22:32 Fabrice Bellard
2005-01-03 23:00 Fabrice Bellard
2004-12-06 22:51 Fabrice Bellard

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=20070211183300.GA3012@localhost.localdomain \
    --to=k.shutemov@gmail.com \
    --cc=qemu-devel@nongnu.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 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).