Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 7 Apr 2018 20:56:07 +0000 (UTC)
From:      Michael Tuexen <tuexen@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r332242 - stable/11/usr.bin/truss
Message-ID:  <201804072056.w37Ku74o003996@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: tuexen
Date: Sat Apr  7 20:56:07 2018
New Revision: 332242
URL: https://svnweb.freebsd.org/changeset/base/332242

Log:
  MFC r327961:
  
  Mark the iovec parameters of writev() and readv() as IN and OUT.
  This makes truss work on readv() as expected.

Modified:
  stable/11/usr.bin/truss/syscalls.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/usr.bin/truss/syscalls.c
==============================================================================
--- stable/11/usr.bin/truss/syscalls.c	Sat Apr  7 20:54:37 2018	(r332241)
+++ stable/11/usr.bin/truss/syscalls.c	Sat Apr  7 20:56:07 2018	(r332242)
@@ -371,7 +371,7 @@ static struct syscall decoded_syscalls[] = {
 	{ .name = "read", .ret_type = 1, .nargs = 3,
 	  .args = { { Int, 0 }, { BinString | OUT, 1 }, { Sizet, 2 } } },
 	{ .name = "readv", .ret_type = 1, .nargs = 3,
-	  .args = { { Int, 0 }, { Iovec, 1 }, { Int, 2 } } },
+	  .args = { { Int, 0 }, { Iovec | OUT, 1 }, { Int, 2 } } },
 	{ .name = "readlink", .ret_type = 1, .nargs = 3,
 	  .args = { { Name, 0 }, { Readlinkres | OUT, 1 }, { Sizet, 2 } } },
 	{ .name = "readlinkat", .ret_type = 1, .nargs = 4,
@@ -507,7 +507,7 @@ static struct syscall decoded_syscalls[] = {
 	{ .name = "write", .ret_type = 1, .nargs = 3,
 	  .args = { { Int, 0 }, { BinString | IN, 1 }, { Sizet, 2 } } },
 	{ .name = "writev", .ret_type = 1, .nargs = 3,
-	  .args = { { Int, 0 }, { Iovec, 1 }, { Int, 2 } } },
+	  .args = { { Int, 0 }, { Iovec | IN, 1 }, { Int, 2 } } },
 
 	/* Linux ABI */
 	{ .name = "linux_access", .ret_type = 1, .nargs = 2,



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201804072056.w37Ku74o003996>