From owner-p4-projects@FreeBSD.ORG Sun Jul 1 05:42:58 2007 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id ADDF516A46B; Sun, 1 Jul 2007 05:42:58 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 3448216A421 for ; Sun, 1 Jul 2007 05:42:58 +0000 (UTC) (envelope-from peter@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [69.147.83.41]) by mx1.freebsd.org (Postfix) with ESMTP id 2533613C45D for ; Sun, 1 Jul 2007 05:42:58 +0000 (UTC) (envelope-from peter@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.8/8.13.8) with ESMTP id l615gwLP062625 for ; Sun, 1 Jul 2007 05:42:58 GMT (envelope-from peter@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.8/8.13.8/Submit) id l615gviH062622 for perforce@freebsd.org; Sun, 1 Jul 2007 05:42:57 GMT (envelope-from peter@freebsd.org) Date: Sun, 1 Jul 2007 05:42:57 GMT Message-Id: <200707010542.l615gviH062622@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to peter@freebsd.org using -f From: Peter Wemm To: Perforce Change Reviews Cc: Subject: PERFORCE change 122613 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Jul 2007 05:42:59 -0000 http://perforce.freebsd.org/chv.cgi?CH=122613 Change 122613 by peter@peter_melody on 2007/07/01 05:42:26 Make the _new_ prefixes disappear. Affected files ... .. //depot/projects/hammer/usr.bin/kdump/kdump.c#17 edit Differences ... ==== //depot/projects/hammer/usr.bin/kdump/kdump.c#17 (text+ko) ==== @@ -308,10 +308,14 @@ int narg = ktr->ktr_narg; register_t *ip; - if (ktr->ktr_code >= nsyscalls || ktr->ktr_code < 0) + if (ktr->ktr_code >= nsyscalls || ktr->ktr_code < 0) { (void)printf("[%d]", ktr->ktr_code); - else - (void)printf("%s", syscallnames[ktr->ktr_code]); + } else { + if (strncmp(syscallnames[ktr->ktr_code], "_new_", 5) == 0) + (void)printf("%s", syscallnames[ktr->ktr_code] + 5); + else + (void)printf("%s", syscallnames[ktr->ktr_code]); + } ip = &ktr->ktr_args[0]; if (narg) { char c = '('; @@ -464,6 +468,17 @@ mmapflagsname ((int)*ip); ip++; narg--; + } else if (ktr->ktr_code == SYS__new_mmap) { + print_number(ip,narg,c); + print_number(ip,narg,c); + (void)putchar(','); + mmapprotname ((int)*ip); + (void)putchar(','); + ip++; + narg--; + mmapflagsname ((int)*ip); + ip++; + narg--; } else if (ktr->ktr_code == SYS_mprotect) { print_number(ip,narg,c); print_number(ip,narg,c); @@ -534,6 +549,15 @@ whencename ((int)*ip); ip++; narg--; + } else if (ktr->ktr_code == SYS__new_lseek) { + print_number(ip,narg,c); + /* Hidden 'pad' argument, not in lseek(2) */ + print_number(ip,narg,c); + (void)putchar(','); + whencename ((int)*ip); + ip++; + narg--; + } else if (ktr->ktr_code == SYS_flock) { print_number(ip,narg,c); (void)putchar(','); @@ -747,10 +771,14 @@ int error = ktr->ktr_error; int code = ktr->ktr_code; - if (code >= nsyscalls || code < 0) + if (code >= nsyscalls || code < 0) { (void)printf("[%d] ", code); - else - (void)printf("%s ", syscallnames[code]); + } else { + if (strncmp(syscallnames[code], "_new_", 5) == 0) + (void)printf("%s ", syscallnames[code] + 5); + else + (void)printf("%s ", syscallnames[code]); + } if (error == 0) { if (fancy) {