2 * Copyright (c) 1991, 1992 Paul Kranenburg <pk@cs.few.eur.nl>
3 * Copyright (c) 1993 Branko Lankester <branko@hacktic.nl>
4 * Copyright (c) 1993, 1994, 1995, 1996 Rick Sladkey <jrs@world.std.com>
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions
10 * 1. Redistributions of source code must retain the above copyright
11 * notice, this list of conditions and the following disclaimer.
12 * 2. Redistributions in binary form must reproduce the above copyright
13 * notice, this list of conditions and the following disclaimer in the
14 * documentation and/or other materials provided with the distribution.
15 * 3. The name of the author may not be used to endorse or promote products
16 * derived from this software without specific prior written permission.
18 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
19 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
20 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
21 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
22 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
23 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
40 # include <sys/cred.h>
45 #ifdef MAJOR_IN_SYSMACROS
46 #include <sys/sysmacros.h>
50 #include <sys/mkdev.h>
53 #ifdef HAVE_SYS_ASYNCH_H
54 #include <sys/asynch.h>
62 * This is a really dirty trick but it should always work. Traditional
63 * Unix says r/w/rw are 0/1/2, so we make them true flags 1/2/3 by
64 * adding 1. Just remember to add 1 to any arg decoded with openmodes.
66 struct xlat openmodes[] = {
67 { O_RDWR+1, "O_RDWR" },
68 { O_RDONLY+1, "O_RDONLY" },
69 { O_WRONLY+1, "O_WRONLY" },
70 { O_NONBLOCK, "O_NONBLOCK" },
71 { O_APPEND, "O_APPEND" },
72 { O_CREAT, "O_CREAT" },
73 { O_TRUNC, "O_TRUNC" },
75 { O_NOCTTY, "O_NOCTTY" },
80 { O_ASYNC, "O_ASYNC" },
83 { O_DSYNC, "O_DSYNC" },
86 { O_RSYNC, "O_RSYNC" },
89 { O_NDELAY, "O_NDELAY" },
95 { O_DIRECT, "O_DIRECT" },
98 { O_LARGEFILE, "O_LARGEFILE" },
101 { O_DIRECTORY, "O_DIRECTORY" },
105 { FNDELAY, "FNDELAY" },
108 { FAPPEND, "FAPPEND" },
114 { FDEFER, "FDEFER" },
117 { FASYNC, "FASYNC" },
120 { FSHLOCK, "FSHLOCK" },
123 { FEXLOCK, "FEXLOCK" },
126 { FCREAT, "FCREAT" },
129 { FTRUNC, "FTRUNC" },
141 { FNOCTTY, "FNOCTTY" },
151 printpath(tcp, tcp->u_arg[0]);
154 printflags(openmodes, tcp->u_arg[1] + 1);
155 if (tcp->u_arg[1] & O_CREAT) {
157 tprintf(", %#lo", tcp->u_arg[2]);
164 struct xlat openmodessol[] = {
168 { 0x80, "O_NONBLOCK" },
170 { 0x100, "O_CREAT" },
171 { 0x200, "O_TRUNC" },
173 { 0x800, "O_NOCTTY" },
176 { 0x8000, "O_RSYNC" },
178 { 0x1000, "O_PRIV" },
187 printpath(tcp, tcp->u_arg[0]);
190 printflags(openmodessol, tcp->u_arg[1] + 1);
191 if (tcp->u_arg[1] & 0x100) {
193 tprintf(", %#lo", tcp->u_arg[2]);
206 printpath(tcp, tcp->u_arg[0]);
207 tprintf(", %#lo", tcp->u_arg[1]);
212 static struct xlat access_flags[] = {
218 { EFF_ONLY_OK, "EFF_ONLY_OK" },
231 printpath(tcp, tcp->u_arg[0]);
233 printflags(access_flags, tcp->u_arg[1]);
243 tprintf("%#lo", tcp->u_arg[0]);
248 static struct xlat whence[] = {
249 { SEEK_SET, "SEEK_SET" },
250 { SEEK_CUR, "SEEK_CUR" },
251 { SEEK_END, "SEEK_END" },
260 tprintf("%ld, ", tcp->u_arg[0]);
261 if (tcp->u_arg[2] == SEEK_SET)
262 tprintf("%lu, ", tcp->u_arg[1]);
264 tprintf("%ld, ", tcp->u_arg[1]);
265 printxval(whence, tcp->u_arg[2], "SEEK_???");
267 return RVAL_UDECIMAL;
276 if (tcp->u_arg[4] == SEEK_SET)
277 tprintf("%ld, %llu, ", tcp->u_arg[0],
278 (((unsigned long long int) tcp->u_arg[1]) << 32
279 | (unsigned long) tcp->u_arg[2]));
281 tprintf("%ld, %lld, ", tcp->u_arg[0],
282 (((long long int) tcp->u_arg[1]) << 32
283 | (unsigned long) tcp->u_arg[2]));
287 tprintf("%#lx, ", tcp->u_arg[3]);
290 umove(tcp, tcp->u_arg[3], &off);
291 tprintf("{%lld}, ", off);
293 printxval(whence, tcp->u_arg[4], "SEEK_???");
304 printpath(tcp, tcp->u_arg[0]);
305 tprintf(", %lu", tcp->u_arg[1]);
315 tprintf("%ld, %lu", tcp->u_arg[0], tcp->u_arg[1]);
322 static struct xlat modetypes[] = {
323 { S_IFREG, "S_IFREG" },
324 { S_IFSOCK, "S_IFSOCK" },
325 { S_IFIFO, "S_IFIFO" },
326 { S_IFLNK, "S_IFLNK" },
327 { S_IFDIR, "S_IFDIR" },
328 { S_IFBLK, "S_IFBLK" },
329 { S_IFCHR, "S_IFCHR" },
340 if ((mode & S_IFMT) == 0)
342 else if ((s = xlookup(modetypes, mode & S_IFMT)) == NULL) {
343 sprintf(buf, "%#o", mode);
346 sprintf(buf, "%s%s%s%s", s,
347 (mode & S_ISUID) ? "|S_ISUID" : "",
348 (mode & S_ISGID) ? "|S_ISGID" : "",
349 (mode & S_ISVTX) ? "|S_ISVTX" : "");
350 mode &= ~(S_IFMT|S_ISUID|S_ISGID|S_ISVTX);
352 sprintf(buf + strlen(buf), "|%#o", mode);
353 s = (*buf == '|') ? buf + 1 : buf;
369 sprintf(buf, "%02d/%02d/%02d-%02d:%02d:%02d",
370 tmp->tm_year, tmp->tm_mon + 1, tmp->tm_mday,
371 tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
383 int st_pad1[3]; /* network id */
392 int st_pad3; /* st_size, off_t expansion */
393 timestruct_t st_atime;
394 timestruct_t st_mtime;
395 timestruct_t st_ctime;
399 int st_pad4[8]; /* expansion area */
403 printstatsol(tcp, addr)
407 struct solstat statbuf;
413 if (syserror(tcp) || !verbose(tcp)) {
414 tprintf("%#x", addr);
417 if (umove(tcp, addr, &statbuf) < 0) {
422 tprintf("{st_dev=makedev(%lu, %lu), st_ino=%lu, st_mode=%s, ",
423 (unsigned long) ((statbuf.st_dev >> 18) & 0x3fff),
424 (unsigned long) (statbuf.st_dev & 0x3ffff),
425 (unsigned long) statbuf.st_ino,
426 sprintmode(statbuf.st_mode));
427 tprintf("st_nlink=%lu, st_uid=%lu, st_gid=%lu, ",
428 (unsigned long) statbuf.st_nlink,
429 (unsigned long) statbuf.st_uid,
430 (unsigned long) statbuf.st_gid);
431 tprintf("st_blksize=%lu, ", (unsigned long) statbuf.st_blksize);
432 tprintf("st_blocks=%lu, ", (unsigned long) statbuf.st_blocks);
435 tprintf("{st_mode=%s, ", sprintmode(statbuf.st_mode));
436 switch (statbuf.st_mode & S_IFMT) {
437 case S_IFCHR: case S_IFBLK:
438 tprintf("st_rdev=makedev(%lu, %lu), ",
439 (unsigned long) ((statbuf.st_rdev >> 18) & 0x3fff),
440 (unsigned long) (statbuf.st_rdev & 0x3ffff));
443 tprintf("st_size=%u, ", statbuf.st_size);
447 tprintf("st_atime=%s, ", sprinttime(statbuf.st_atime));
448 tprintf("st_mtime=%s, ", sprinttime(statbuf.st_mtime));
449 tprintf("st_ctime=%s}", sprinttime(statbuf.st_ctime));
457 /* Get the kernel's idea of struct stat. */
458 #define stat kernel_stat
459 #include <asm/stat.h>
462 #define kernel_stat stat
470 struct kernel_stat statbuf;
473 if (current_personality == 1) {
474 printstatsol(tcp, addr);
477 #endif /* LINUXSPARC */
483 if (syserror(tcp) || !verbose(tcp)) {
484 tprintf("%#x", addr);
487 if (umove(tcp, addr, &statbuf) < 0) {
492 tprintf("{st_dev=makedev(%lu, %lu), st_ino=%lu, st_mode=%s, ",
493 (unsigned long) major(statbuf.st_dev),
494 (unsigned long) minor(statbuf.st_dev),
495 (unsigned long) statbuf.st_ino,
496 sprintmode(statbuf.st_mode));
497 tprintf("st_nlink=%lu, st_uid=%lu, st_gid=%lu, ",
498 (unsigned long) statbuf.st_nlink,
499 (unsigned long) statbuf.st_uid,
500 (unsigned long) statbuf.st_gid);
501 #ifdef HAVE_ST_BLKSIZE
502 tprintf("st_blksize=%lu, ", (unsigned long) statbuf.st_blksize);
503 #endif /* HAVE_ST_BLKSIZE */
504 #ifdef HAVE_ST_BLOCKS
505 tprintf("st_blocks=%lu, ", (unsigned long) statbuf.st_blocks);
506 #endif /* HAVE_ST_BLOCKS */
509 tprintf("{st_mode=%s, ", sprintmode(statbuf.st_mode));
510 switch (statbuf.st_mode & S_IFMT) {
511 case S_IFCHR: case S_IFBLK:
513 tprintf("st_rdev=makedev(%lu, %lu), ",
514 (unsigned long) major(statbuf.st_rdev),
515 (unsigned long) minor(statbuf.st_rdev));
516 #else /* !HAVE_ST_RDEV */
517 tprintf("st_size=makedev(%lu, %lu), ",
518 (unsigned long) major(statbuf.st_size),
519 (unsigned long) minor(statbuf.st_size));
520 #endif /* !HAVE_ST_RDEV */
523 tprintf("st_size=%lu, ", statbuf.st_size);
527 tprintf("st_atime=%s, ", sprinttime(statbuf.st_atime));
528 tprintf("st_mtime=%s, ", sprinttime(statbuf.st_mtime));
529 tprintf("st_ctime=%s}", sprinttime(statbuf.st_ctime));
540 printpath(tcp, tcp->u_arg[0]);
543 printstat(tcp, tcp->u_arg[1]);
553 tprintf("%ld, ", tcp->u_arg[0]);
555 printstat(tcp, tcp->u_arg[1]);
565 printpath(tcp, tcp->u_arg[0]);
568 printstat(tcp, tcp->u_arg[1]);
573 #if defined(SVR4) || defined(LINUXSPARC)
580 tprintf("%ld, ", tcp->u_arg[0]);
581 printpath(tcp, tcp->u_arg[1]);
584 printstat(tcp, tcp->u_arg[2]);
594 tprintf("%ld, %ld, ", tcp->u_arg[0], tcp->u_arg[1]);
596 printstat(tcp, tcp->u_arg[2]);
606 tprintf("%ld, ", tcp->u_arg[0]);
607 printpath(tcp, tcp->u_arg[1]);
610 printstat(tcp, tcp->u_arg[2]);
619 int mode = tcp->u_arg[2];
622 tprintf("%ld, ", tcp->u_arg[0]);
623 printpath(tcp, tcp->u_arg[1]);
624 tprintf(", %s", sprintmode(mode));
625 switch (mode & S_IFMT) {
626 case S_IFCHR: case S_IFBLK:
628 tprintf(", makedev(%lu, %lu)",
629 (unsigned long) ((tcp->u_arg[3] >> 18) & 0x3fff),
630 (unsigned long) (tcp->u_arg[3] & 0x3ffff));
632 tprintf(", makedev(%lu, %lu)",
633 (unsigned long) major(tcp->u_arg[3]),
634 (unsigned long) minor(tcp->u_arg[3]));
644 #endif /* SVR4 || LINUXSPARC */
648 static struct xlat fsmagic[] = {
649 { 0xef51, "EXT2_OLD_SUPER_MAGIC" },
650 { 0xef53, "EXT2_SUPER_MAGIC" },
651 { 0x137d, "EXT_SUPER_MAGIC" },
652 { 0x9660, "ISOFS_SUPER_MAGIC" },
653 { 0x137f, "MINIX_SUPER_MAGIC" },
654 { 0x138f, "MINIX_SUPER_MAGIC2" },
655 { 0x2468, "NEW_MINIX_SUPER_MAGIC" },
656 { 0x4d44, "MSDOS_SUPER_MAGIC" },
657 { 0x6969, "NFS_SUPER_MAGIC" },
658 { 0x9fa0, "PROC_SUPER_MAGIC" },
659 { 0x012fd16d, "XIAFS_SUPER_MAGIC" },
675 s = xlookup(fsmagic, magic);
677 sprintf(buf, "\"%s\"", s);
681 sprintf(buf, "%#x", magic);
686 printstatfs(tcp, addr)
690 struct statfs statbuf;
692 if (syserror(tcp) || !verbose(tcp)) {
693 tprintf("%#lx", addr);
696 if (umove(tcp, addr, &statbuf) < 0) {
702 tprintf("{f_type=%s, f_fbsize=%u, f_blocks=%u, f_bfree=%u, ",
703 sprintfstype(statbuf.f_type),
704 statbuf.f_bsize, statbuf.f_blocks, statbuf.f_bfree);
705 tprintf("f_bavail=%u, f_files=%u, f_ffree=%u, f_namelen=%u}",
706 statbuf.f_bavail,statbuf.f_files, statbuf.f_ffree, statbuf.f_namelen);
708 tprintf("{f_type=%s, f_bsize=%lu, f_blocks=%lu, f_bfree=%lu, ",
709 sprintfstype(statbuf.f_type),
710 statbuf.f_bsize, statbuf.f_blocks, statbuf.f_bfree);
711 tprintf("f_files=%lu, f_ffree=%lu",
712 statbuf.f_files, statbuf.f_ffree);
714 tprintf(", f_namelen=%lu}", statbuf.f_namelen);
725 printpath(tcp, tcp->u_arg[0]);
728 printstatfs(tcp, tcp->u_arg[1]);
738 tprintf("%lu, ", tcp->u_arg[0]);
740 printstatfs(tcp, tcp->u_arg[1]);
753 printpath(tcp, tcp->u_arg[0]);
756 printstatfs(tcp, tcp->u_arg[1]);
757 tprintf(", %lu", tcp->u_arg[2]);
767 tprintf("%lu, ", tcp->u_arg[0]);
769 printstatfs(tcp, tcp->u_arg[1]);
770 tprintf(", %lu", tcp->u_arg[2]);
785 struct ustat statbuf;
788 tprintf("makedev(%lu, %lu), ",
789 (long) major(tcp->u_arg[0]),
790 (long) minor(tcp->u_arg[0]));
793 if (syserror(tcp) || !verbose(tcp))
794 tprintf("%#lx", tcp->u_arg[1]);
795 else if (umove(tcp, tcp->u_arg[1], &statbuf) < 0)
798 tprintf("{f_tfree=%lu, f_tinode=%lu, ",
799 statbuf.f_tfree, statbuf.f_tinode);
800 tprintf("f_fname=\"%.*s\", ",
801 (int) sizeof(statbuf.f_fname),
803 tprintf("f_fpack=\"%.*s\"}",
804 (int) sizeof(statbuf.f_fpack),
819 printpath(tcp, tcp->u_arg[0]);
829 printpath(tcp, tcp->u_arg[0]);
830 tprintf(", %#lo", tcp->u_arg[1]);
840 printpath(tcp, tcp->u_arg[0]);
850 tprintf("%ld", tcp->u_arg[0]);
860 printpath(tcp, tcp->u_arg[0]);
870 tprintf("%ld", tcp->u_arg[0]);
880 printpath(tcp, tcp->u_arg[0]);
882 printpath(tcp, tcp->u_arg[1]);
892 printpath(tcp, tcp->u_arg[0]);
902 printpath(tcp, tcp->u_arg[0]);
904 printpath(tcp, tcp->u_arg[1]);
914 printpath(tcp, tcp->u_arg[0]);
918 tprintf("%#lx", tcp->u_arg[1]);
920 printpathn(tcp, tcp->u_arg[1], tcp->u_rval);
921 tprintf(", %lu", tcp->u_arg[2]);
931 printpath(tcp, tcp->u_arg[0]);
933 printpath(tcp, tcp->u_arg[1]);
943 printpath(tcp, tcp->u_arg[0]);
944 tprintf(", %lu, %lu", tcp->u_arg[1], tcp->u_arg[2]);
954 tprintf("%ld, %lu, %lu",
955 tcp->u_arg[0], tcp->u_arg[1], tcp->u_arg[2]);
965 printpath(tcp, tcp->u_arg[0]);
966 tprintf(", %#lo", tcp->u_arg[1]);
976 tprintf("%ld, %#lo", tcp->u_arg[0], tcp->u_arg[1]);
986 printpath(tcp, tcp->u_arg[0]);
988 printtv(tcp, tcp->u_arg[1]);
1000 printpath(tcp, tcp->u_arg[0]);
1004 else if (!verbose(tcp))
1005 tprintf("%#lx", tcp->u_arg[1]);
1006 else if (umoven(tcp, tcp->u_arg[1], sizeof ut,
1010 tprintf("[%s,", sprinttime(ut[0]));
1011 tprintf(" %s]", sprinttime(ut[1]));
1021 int mode = tcp->u_arg[1];
1023 if (entering(tcp)) {
1024 printpath(tcp, tcp->u_arg[0]);
1025 tprintf(", %s", sprintmode(mode));
1026 switch (mode & S_IFMT) {
1027 case S_IFCHR: case S_IFBLK:
1029 if (current_personality == 1)
1030 tprintf(", makedev(%lu, %lu)",
1031 (unsigned long) ((tcp->u_arg[2] >> 18) & 0x3fff),
1032 (unsigned long) (tcp->u_arg[2] & 0x3ffff));
1035 tprintf(", makedev(%lu, %lu)",
1036 (unsigned long) major(tcp->u_arg[2]),
1037 (unsigned long) minor(tcp->u_arg[2]));
1050 if (entering(tcp)) {
1051 printpath(tcp, tcp->u_arg[0]);
1052 tprintf(", %#lo", tcp->u_arg[1]);
1061 if (entering(tcp)) {
1062 tprintf("%ld", tcp->u_arg[0]);
1076 if (!verbose(tcp)) {
1077 tprintf("%#lx", addr);
1080 if (umove(tcp, addr, &d) < 0) {
1084 tprintf("{d_ino=%ld, ", (unsigned long) d.d_ino);
1086 /* This contains garbage under Linux. */
1087 tprintf("d_off=%d, ", d.d_off);
1090 /* No point in printing this out since the syscall returns it. */
1091 tprintf("d_reclen=%u, ", d.d_reclen);
1094 printpathn(tcp, (long) ((struct dirent *) addr)->d_name, d.d_reclen);
1102 if (entering(tcp)) {
1103 tprintf("%lu, ", tcp->u_arg[0]);
1105 if (syserror(tcp) || tcp->u_rval == 0 || !verbose(tcp))
1106 tprintf("%#lx", tcp->u_arg[1]);
1108 printdir(tcp, tcp->u_arg[1]);
1109 /* Not much point in printing this out, it is always 1. */
1110 if (tcp->u_arg[2] != 1)
1111 tprintf(", %lu", tcp->u_arg[2]);
1122 int i, len, dents = 0;
1125 if (entering(tcp)) {
1126 tprintf("%lu, ", tcp->u_arg[0]);
1129 if (syserror(tcp) || !verbose(tcp)) {
1130 tprintf("%#lx, %lu", tcp->u_arg[1], tcp->u_arg[2]);
1135 tprintf (" = Unknown value\n");
1140 if ((buf = malloc(len)) == NULL) {
1141 tprintf("out of memory\n");
1144 if (umoven(tcp, tcp->u_arg[1], len, buf) < 0) {
1145 tprintf("{...}, %lu", tcp->u_arg[2]);
1151 for (i = 0; i < len;) {
1152 struct dirent *d = (struct dirent *) &buf[i];
1155 tprintf("%s{d_ino=%lu, d_off=%lu, ",
1156 i ? " " : "", d->d_ino, d->d_off);
1157 tprintf("d_reclen=%u, d_name=\"%s\"}",
1158 d->d_reclen, d->d_name);
1163 tprintf("%s{d_ino=%lu, d_off=%lu, ",
1164 i ? " " : "", d->d_ino, d->d_off);
1165 tprintf("d_reclen=%u, d_name=\"%s\"}",
1166 d->d_reclen, d->d_name);
1171 tprintf("%s{d_off=%lu, d_fileno=%lu, d_reclen=%u, ",
1172 i ? " " : "", d->d_off, d->d_fileno,
1174 tprintf("d_namlen=%u, d_name=\"%.*s\"}",
1175 d->d_namlen, d->d_namlen, d->d_name);
1184 tprintf("/* %u entries */", dents);
1185 tprintf(", %lu", tcp->u_arg[2]);
1198 tprintf("%#lx", tcp->u_arg[0]);
1200 printstr(tcp, tcp->u_arg[0], tcp->u_arg[1]);
1201 tprintf(", %lu", tcp->u_arg[1]);
1207 #ifdef HAVE_SYS_ASYNCH_H
1213 struct aio_result_t res;
1215 if (entering(tcp)) {
1216 tprintf("%lu, ", tcp->u_arg[0]);
1219 tprintf("%#lx", tcp->u_arg[1]);
1221 printstr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
1222 tprintf(", %lu, %lu, ", tcp->u_arg[2], tcp->u_arg[3]);
1223 printxval(whence, tcp->u_arg[4], "L_???");
1224 if (syserror(tcp) || tcp->u_arg[5] == 0
1225 || umove(tcp, tcp->u_arg[5], &res) < 0)
1226 tprintf(", %#lx", tcp->u_arg[5]);
1228 tprintf(", {aio_return %d aio_errno %d}",
1229 res.aio_return, res.aio_errno);
1238 struct aio_result_t res;
1240 if (entering(tcp)) {
1241 tprintf("%lu, ", tcp->u_arg[0]);
1242 printstr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
1243 tprintf(", %lu, %lu, ", tcp->u_arg[2], tcp->u_arg[3]);
1244 printxval(whence, tcp->u_arg[4], "L_???");
1247 if (tcp->u_arg[5] == 0)
1249 else if (syserror(tcp)
1250 || umove(tcp, tcp->u_arg[5], &res) < 0)
1251 tprintf(", %#lx", tcp->u_arg[5]);
1253 tprintf(", {aio_return %d aio_errno %d}",
1254 res.aio_return, res.aio_errno);
1264 printtv(tcp, tcp->u_arg[0]);
1272 struct aio_result_t res;
1275 if (tcp->u_arg[0] == 0)
1277 else if (syserror(tcp)
1278 || umove(tcp, tcp->u_arg[0], &res) < 0)
1279 tprintf("%#lx", tcp->u_arg[0]);
1281 tprintf("{aio_return %d aio_errno %d}",
1282 res.aio_return, res.aio_errno);
1287 #endif /* HAVE_SYS_ASYNCH_H */