diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2015-07-27 22:20:28 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2015-07-27 22:20:28 +0000 |
| commit | 5f78ec1c9f70cd1e2e348d374a4c6aabfde7795b (patch) | |
| tree | 38628b1289f1c465af2ce50de529a269a17e51af /usr.bin | |
| parent | 8d0f10857a48c0f5e04bf0cbe3d7443cb4f8051a (diff) | |
| parent | 7d477dc35a25405bcc41870a66845ae1aa7d72f3 (diff) | |
Notes
Diffstat (limited to 'usr.bin')
| -rw-r--r-- | usr.bin/Makefile | 1 | ||||
| -rw-r--r-- | usr.bin/ar/ar.1 | 23 | ||||
| -rw-r--r-- | usr.bin/ar/ar.c | 18 | ||||
| -rw-r--r-- | usr.bin/elfdump/elfdump.c | 1 | ||||
| -rw-r--r-- | usr.bin/grep/Makefile | 2 | ||||
| -rw-r--r-- | usr.bin/ident/Makefile | 13 | ||||
| -rw-r--r-- | usr.bin/ident/ident.1 | 68 | ||||
| -rw-r--r-- | usr.bin/ident/ident.c | 242 | ||||
| -rw-r--r-- | usr.bin/ident/tests/Makefile | 11 | ||||
| -rwxr-xr-x | usr.bin/ident/tests/ident.sh | 16 | ||||
| -rw-r--r-- | usr.bin/ident/tests/test.in | 15 | ||||
| -rw-r--r-- | usr.bin/ident/tests/test.out | 6 | ||||
| -rw-r--r-- | usr.bin/ident/tests/testnoid | 0 | ||||
| -rwxr-xr-x | usr.bin/man/man.sh | 4 | ||||
| -rw-r--r-- | usr.bin/truss/amd64-fbsd.c | 1 | ||||
| -rw-r--r-- | usr.bin/truss/amd64-fbsd32.c | 1 | ||||
| -rw-r--r-- | usr.bin/truss/arm-fbsd.c | 1 | ||||
| -rw-r--r-- | usr.bin/truss/i386-fbsd.c | 1 | ||||
| -rw-r--r-- | usr.bin/truss/mips-fbsd.c | 1 | ||||
| -rw-r--r-- | usr.bin/truss/powerpc-fbsd.c | 1 | ||||
| -rw-r--r-- | usr.bin/truss/powerpc64-fbsd.c | 1 | ||||
| -rw-r--r-- | usr.bin/truss/sparc64-fbsd.c | 1 |
22 files changed, 421 insertions, 7 deletions
diff --git a/usr.bin/Makefile b/usr.bin/Makefile index fd786025fa78..cf5604c79a06 100644 --- a/usr.bin/Makefile +++ b/usr.bin/Makefile @@ -64,6 +64,7 @@ SUBDIR= ${_addr2line} \ hexdump \ ${_iconv} \ id \ + ident \ ipcrm \ ipcs \ join \ diff --git a/usr.bin/ar/ar.1 b/usr.bin/ar/ar.1 index 1ef8c89fd7ed..02e99f1a92c9 100644 --- a/usr.bin/ar/ar.1 +++ b/usr.bin/ar/ar.1 @@ -23,7 +23,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 22, 2011 +.Dd July 24, 2015 .Dt AR 1 .Os .Sh NAME @@ -66,6 +66,7 @@ .Op Fl D .Op Fl f .Op Fl s | Fl S +.Op Fl U .Op Fl v .Op Fl z .Ar archive @@ -82,6 +83,7 @@ .Op Fl j .Op Fl s | Fl S .Op Fl u +.Op Fl U .Op Fl v .Op Fl z .Ar archive @@ -112,6 +114,7 @@ .Fl M .Nm ranlib .Op Fl D +.Op Fl U .Ar archive ... .Sh DESCRIPTION The @@ -207,6 +210,11 @@ and 0644 instead of file mode from the members named by arguments .Ar . This ensures that checksums on the resulting archives are reproducible when member contents are identical. +If multiple +.Fl D +and +.Fl U +options are specified on the command line, the final one takes precedence. .It Fl f Synonymous with option .Fl T . @@ -316,6 +324,19 @@ option, the members specified by arguments .Ar will be extracted only if they are newer than the corresponding files in the file system. +.It Fl U +When used in combination with the +.Fl r +or +.Fl q +option, insert the real mtime, uid and gid, and file mode values +from the members named by arguments +.Ar . +If multiple +.Fl D +and +.Fl U +options are specified on the command line, the final one takes precedence. .It Fl v Provide verbose output. When used with the diff --git a/usr.bin/ar/ar.c b/usr.bin/ar/ar.c index 7c76290207ea..3d5e2b87667b 100644 --- a/usr.bin/ar/ar.c +++ b/usr.bin/ar/ar.c @@ -113,7 +113,7 @@ main(int argc, char **argv) len = strlen(bsdar->progname); if (len >= strlen("ranlib") && strcmp(bsdar->progname + len - strlen("ranlib"), "ranlib") == 0) { - while ((opt = getopt_long(argc, argv, "tDV", longopts, + while ((opt = getopt_long(argc, argv, "tDUV", longopts, NULL)) != -1) { switch(opt) { case 't': @@ -122,6 +122,9 @@ main(int argc, char **argv) case 'D': bsdar->options |= AR_D; break; + case 'U': + bsdar->options &= ~AR_D; + break; case 'V': ranlib_version(); break; @@ -157,7 +160,7 @@ main(int argc, char **argv) } } - while ((opt = getopt_long(argc, argv, "abCcdDfijlMmopqrSsTtuVvxz", + while ((opt = getopt_long(argc, argv, "abCcdDfijlMmopqrSsTtUuVvxz", longopts, NULL)) != -1) { switch(opt) { case 'a': @@ -216,6 +219,9 @@ main(int argc, char **argv) case 't': set_mode(bsdar, opt); break; + case 'U': + bsdar->options &= ~AR_D; + break; case 'u': bsdar->options |= AR_U; break; @@ -364,9 +370,9 @@ bsdar_usage(void) (void)fprintf(stderr, "\tar -m [-Tjsvz] archive file ...\n"); (void)fprintf(stderr, "\tar -m [-Tabijsvz] position archive file ...\n"); (void)fprintf(stderr, "\tar -p [-Tv] archive [file ...]\n"); - (void)fprintf(stderr, "\tar -q [-TcDjsvz] archive file ...\n"); - (void)fprintf(stderr, "\tar -r [-TcDjsuvz] archive file ...\n"); - (void)fprintf(stderr, "\tar -r [-TabcDijsuvz] position archive file ...\n"); + (void)fprintf(stderr, "\tar -q [-TcDjsUvz] archive file ...\n"); + (void)fprintf(stderr, "\tar -r [-TcDjsUuvz] archive file ...\n"); + (void)fprintf(stderr, "\tar -r [-TabcDijsUuvz] position archive file ...\n"); (void)fprintf(stderr, "\tar -s [-jz] archive\n"); (void)fprintf(stderr, "\tar -t [-Tv] archive [file ...]\n"); (void)fprintf(stderr, "\tar -x [-CTouv] archive [file ...]\n"); @@ -378,7 +384,7 @@ static void ranlib_usage(void) { - (void)fprintf(stderr, "usage: ranlib [-t] archive ...\n"); + (void)fprintf(stderr, "usage: ranlib [-DtU] archive ...\n"); (void)fprintf(stderr, "\tranlib -V\n"); exit(EX_USAGE); } diff --git a/usr.bin/elfdump/elfdump.c b/usr.bin/elfdump/elfdump.c index cd10ce3141d3..2147fcb3179b 100644 --- a/usr.bin/elfdump/elfdump.c +++ b/usr.bin/elfdump/elfdump.c @@ -272,6 +272,7 @@ e_machines(u_int mach) case EM_IA_64: return "EM_IA_64"; case EM_X86_64: return "EM_X86_64"; case EM_AARCH64:return "EM_AARCH64"; + case EM_RISCV: return "EM_RISCV"; } snprintf(machdesc, sizeof(machdesc), "(unknown machine) -- type 0x%x", mach); diff --git a/usr.bin/grep/Makefile b/usr.bin/grep/Makefile index af2147180031..1c0e8ccd362d 100644 --- a/usr.bin/grep/Makefile +++ b/usr.bin/grep/Makefile @@ -20,6 +20,8 @@ SRCS= file.c grep.c queue.c util.c SRCS+= fastmatch.c hashtable.c tre-compile.c tre-fastmatch.c xmalloc.c CFLAGS+=-I${.CURDIR}/regex +CFLAGS.gcc+= --param max-inline-insns-single=500 + .if ${MK_BSD_GREP} == "yes" LINKS= ${BINDIR}/grep ${BINDIR}/egrep \ ${BINDIR}/grep ${BINDIR}/fgrep \ diff --git a/usr.bin/ident/Makefile b/usr.bin/ident/Makefile new file mode 100644 index 000000000000..49798e8251fe --- /dev/null +++ b/usr.bin/ident/Makefile @@ -0,0 +1,13 @@ +# $FreeBSD$ + +.include <src.opts.mk> + +PROG= ident + +LIBADD= sbuf + +.if ${MK_TESTS} != "no" +SUBDIR+= tests +.endif + +.include <bsd.prog.mk> diff --git a/usr.bin/ident/ident.1 b/usr.bin/ident/ident.1 new file mode 100644 index 000000000000..183a578e3309 --- /dev/null +++ b/usr.bin/ident/ident.1 @@ -0,0 +1,68 @@ +.\" Copyright (c) 2015 Baptiste Daroussin <bapt@FreeBSD.org> +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD$ +.\" +.Dd Jul 25, 2015 +.Dt IDENT 1 +.Os +.Sh NAME +.Nm ident +.Nd identify RCS keyword string in files +.Sh SYNOPSIS +.Nm +.Op Fl q +.Op Fl V +.Op Ar File Ns s +.Sh DESCRIPTION +The +.Nm +utility searches for all instances of the pattern +.Sq $keyword: text$ +in +.Ar files . +.Pp +If no arguments are passed, then +.Nm +parses the standard input. +.Pp +.Em keyword +must only be composed of alphanumeric values in the C locale, followed by +.Sq \&: +and a space. +.Pp +These options are supported: +.Bl -tag -width "XXX" +.It Fl q +Quiet mode: suppress warnings if no pattern found. +.It Fl V +Do nothing, added for compatibility with GNU ident. +.El +.Sh EXIT STATUS +.Ex -std ident +.Sh AUTHORS +This version of the +.Nm +utility was written by +.An Baptiste Daroussin Aq Mt bapt@FreeBSD.org . diff --git a/usr.bin/ident/ident.c b/usr.bin/ident/ident.c new file mode 100644 index 000000000000..36e56a0cefda --- /dev/null +++ b/usr.bin/ident/ident.c @@ -0,0 +1,242 @@ +/*- + * Copyright (c) 2015 Baptiste Daroussin <bapt@FreeBSD.org> + * Copyright (c) 2015 Xin LI <delphij@FreeBSD.org> + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer + * in this position and unchanged. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include <sys/cdefs.h> +__FBSDID("$FreeBSD$"); + +#include <sys/types.h> +#include <sys/sbuf.h> + +#include <ctype.h> +#include <err.h> +#include <stdbool.h> +#include <stdio.h> +#include <stdlib.h> +#include <unistd.h> +#include <xlocale.h> + +typedef enum { + /* state condition to transit to next state */ + INIT, /* '$' */ + DELIM_SEEN, /* letter */ + KEYWORD, /* punctuation mark */ + PUNC_SEEN, /* ':' -> _SVN; space -> TEXT */ + PUNC_SEEN_SVN, /* space */ + TEXT +} analyzer_states; + +static int +scan(FILE *fp, const char *name, bool quiet) +{ + int c; + bool hasid = false; + bool subversion = false; + analyzer_states state = INIT; + struct sbuf *id = sbuf_new_auto(); + locale_t l; + + l = newlocale(LC_ALL_MASK, "C", NULL); + + if (name != NULL) + printf("%s:\n", name); + + while ((c = fgetc(fp)) != EOF) { + switch (state) { + case INIT: + if (c == '$') { + /* Transit to DELIM_SEEN if we see $ */ + state = DELIM_SEEN; + } else { + /* Otherwise, stay in INIT state */ + continue; + } + break; + case DELIM_SEEN: + if (isalpha_l(c, l)) { + /* Transit to KEYWORD if we see letter */ + sbuf_clear(id); + sbuf_putc(id, '$'); + sbuf_putc(id, c); + state = KEYWORD; + + continue; + } else if (c == '$') { + /* Or, stay in DELIM_SEEN if more $ */ + continue; + } else { + /* Otherwise, transit back to INIT */ + state = INIT; + } + break; + case KEYWORD: + sbuf_putc(id, c); + + if (isalpha_l(c, l)) { + /* + * Stay in KEYWORD if additional letter is seen + */ + continue; + } else if (c == ':') { + /* + * See ':' for the first time, transit to + * PUNC_SEEN. + */ + state = PUNC_SEEN; + subversion = false; + } else if (c == '$') { + /* + * Incomplete ident. Go back to DELIM_SEEN + * state because we see a '$' which could be + * the beginning of a keyword. + */ + state = DELIM_SEEN; + } else { + /* + * Go back to INIT state otherwise. + */ + state = INIT; + } + break; + case PUNC_SEEN: + case PUNC_SEEN_SVN: + sbuf_putc(id, c); + + switch (c) { + case ':': + /* + * If we see '::' (seen : in PUNC_SEEN), + * activate subversion treatment and transit + * to PUNC_SEEN_SVN state. + * + * If more than two :'s were seen, the ident + * is invalid and we would therefore go back + * to INIT state. + */ + if (state == PUNC_SEEN) { + state = PUNC_SEEN_SVN; + subversion = true; + } else { + state = INIT; + } + break; + case ' ': + /* + * A space after ':' or '::' indicates we are at the + * last component of potential ident. + */ + state = TEXT; + break; + default: + /* All other characters are invalid */ + state = INIT; + break; + } + break; + case TEXT: + sbuf_putc(id, c); + + if (iscntrl_l(c, l)) { + /* Control characters are not allowed in this state */ + state = INIT; + } else if (c == '$') { + sbuf_finish(id); + /* + * valid ident should end with a space. + * + * subversion extension uses '#' to indicate that + * the keyword expansion have exceeded the fixed + * width, so it is also permitted if we are in + * subversion mode. No length check is enforced + * because GNU RCS ident(1) does not do it either. + */ + c = sbuf_data(id)[sbuf_len(id) - 2]; + if (c == ' ' || (subversion && c == '#')) { + printf(" %s\n", sbuf_data(id)); + hasid = true; + } + state = INIT; + } + /* Other characters: stay in the state */ + break; + } + } + sbuf_delete(id); + freelocale(l); + + if (!hasid) { + if (!quiet) + fprintf(stderr, "%s warning: no id keywords in %s\n", + getprogname(), name ? name : "standard input"); + + return (EXIT_FAILURE); + } + + return (EXIT_SUCCESS); +} + +int +main(int argc, char **argv) +{ + bool quiet = false; + int ch, i; + int ret = EXIT_SUCCESS; + FILE *fp; + + while ((ch = getopt(argc, argv, "qV")) != -1) { + switch (ch) { + case 'q': + quiet = true; + break; + case 'V': + /* Do nothing, compat with GNU rcs's ident */ + return (EXIT_SUCCESS); + default: + errx(EXIT_FAILURE, "usage: %s [-q] [-V] [file...]", + getprogname()); + } + } + + argc -= optind; + argv += optind; + + if (argc == 0) + return (scan(stdin, NULL, quiet)); + + for (i = 0; i < argc; i++) { + fp = fopen(argv[i], "r"); + if (fp == NULL) { + warn("%s", argv[i]); + ret = EXIT_FAILURE; + continue; + } + if (scan(fp, argv[i], quiet) != EXIT_SUCCESS) + ret = EXIT_FAILURE; + fclose(fp); + } + + return (ret); +} diff --git a/usr.bin/ident/tests/Makefile b/usr.bin/ident/tests/Makefile new file mode 100644 index 000000000000..cc29bb8c6f8e --- /dev/null +++ b/usr.bin/ident/tests/Makefile @@ -0,0 +1,11 @@ +# $FreeBSD$ + +TESTSDIR= ${TESTSBASE}/usr.bin/ident + +ATF_TESTS_SH= ident +FILES= test.in \ + test.out \ + testnoid +FILESDIR= ${TESTSDIR} + +.include <bsd.test.mk> diff --git a/usr.bin/ident/tests/ident.sh b/usr.bin/ident/tests/ident.sh new file mode 100755 index 000000000000..5a3118254bfa --- /dev/null +++ b/usr.bin/ident/tests/ident.sh @@ -0,0 +1,16 @@ +# $FreeBSD$ + +atf_test_case ident +ident_body() { + atf_check -o file:$(atf_get_srcdir)/test.out \ + ident < $(atf_get_srcdir)/test.in + atf_check -o match:'Foo.*' -s exit:1 \ + -e inline:"ident warning: no id keywords in $(atf_get_srcdir)/testnoid\n" \ + ident $(atf_get_srcdir)/test.in $(atf_get_srcdir)/testnoid + atf_check -o match:'Foo.*' -s exit:1 \ + ident -q $(atf_get_srcdir)/test.in $(atf_get_srcdir)/testnoid +} +atf_init_test_cases() +{ + atf_add_test_case ident +} diff --git a/usr.bin/ident/tests/test.in b/usr.bin/ident/tests/test.in new file mode 100644 index 000000000000..634943833ce5 --- /dev/null +++ b/usr.bin/ident/tests/test.in @@ -0,0 +1,15 @@ +# tranditional + $Foo: bar $ (OK traditional) + $$Foo: bar $ + $$Fo$o: bar $ + $Fo$o: bar $ + $ Foo : bar $ (WRONG -- NON ALPHANUM BEFORE :) + $ Foo : bar $ (WRONG -- NON ALPHANUM BEFORE :) + $Foo: bar $ (WRONG -- NO SPACE AFTER :) + $Foo:bar $ (WRONG -- NO SPACE AFTER :) + $Foo: bar$ (WRONG -- NO SPACE BEFORE $)) +# Subversion like + $Bar:: baz$ (WRONG -- NO SPACE BEFORE $) + $Bar:: baz $ (OK -- SPACE BEFORE $) + $Qux:: frobby zow#$ (OK -- HASH BEFORE $)' ' + diff --git a/usr.bin/ident/tests/test.out b/usr.bin/ident/tests/test.out new file mode 100644 index 000000000000..36cccc9b2098 --- /dev/null +++ b/usr.bin/ident/tests/test.out @@ -0,0 +1,6 @@ + $Foo: bar $ + $Foo: bar $ + $o: bar $ + $o: bar $ + $Bar:: baz $ + $Qux:: frobby zow#$ diff --git a/usr.bin/ident/tests/testnoid b/usr.bin/ident/tests/testnoid new file mode 100644 index 000000000000..e69de29bb2d1 --- /dev/null +++ b/usr.bin/ident/tests/testnoid diff --git a/usr.bin/man/man.sh b/usr.bin/man/man.sh index 5e4d767a3064..e125e5be3f85 100755 --- a/usr.bin/man/man.sh +++ b/usr.bin/man/man.sh @@ -925,6 +925,8 @@ whatis_usage() { # Supported commands do_apropos() { + [ $(stat -f %i /usr/bin/man) -ne $(stat -f %i /usr/bin/apropos) ] && \ + exec apropos "$@" search_whatis apropos "$@" } @@ -960,6 +962,8 @@ do_manpath() { } do_whatis() { + [ $(stat -f %i /usr/bin/man) -ne $(stat -f %i /usr/bin/whatis) ] && \ + exec whatis "$@" search_whatis whatis "$@" } diff --git a/usr.bin/truss/amd64-fbsd.c b/usr.bin/truss/amd64-fbsd.c index 516c4d280caf..d0be3e6b141a 100644 --- a/usr.bin/truss/amd64-fbsd.c +++ b/usr.bin/truss/amd64-fbsd.c @@ -158,6 +158,7 @@ amd64_syscall_entry(struct trussinfo *trussinfo, int nargs) if (fsc->name && (trussinfo->flags & FOLLOWFORKS) && (strcmp(fsc->name, "fork") == 0 || + strcmp(fsc->name, "pdfork") == 0 || strcmp(fsc->name, "rfork") == 0 || strcmp(fsc->name, "vfork") == 0)) trussinfo->curthread->in_fork = 1; diff --git a/usr.bin/truss/amd64-fbsd32.c b/usr.bin/truss/amd64-fbsd32.c index 72f42958183e..74d45a2189d5 100644 --- a/usr.bin/truss/amd64-fbsd32.c +++ b/usr.bin/truss/amd64-fbsd32.c @@ -165,6 +165,7 @@ amd64_fbsd32_syscall_entry(struct trussinfo *trussinfo, int nargs) if (fsc->name && (trussinfo->flags & FOLLOWFORKS) && (strcmp(fsc->name, "fork") == 0 || + strcmp(fsc->name, "pdfork") == 0 || strcmp(fsc->name, "rfork") == 0 || strcmp(fsc->name, "vfork") == 0)) trussinfo->curthread->in_fork = 1; diff --git a/usr.bin/truss/arm-fbsd.c b/usr.bin/truss/arm-fbsd.c index 3bac40095c7c..dd1ae0896483 100644 --- a/usr.bin/truss/arm-fbsd.c +++ b/usr.bin/truss/arm-fbsd.c @@ -172,6 +172,7 @@ arm_syscall_entry(struct trussinfo *trussinfo, int nargs) if (fsc->name && (trussinfo->flags & FOLLOWFORKS) && (strcmp(fsc->name, "fork") == 0 || + strcmp(fsc->name, "pdfork") == 0 || strcmp(fsc->name, "rfork") == 0 || strcmp(fsc->name, "vfork") == 0)) trussinfo->curthread->in_fork = 1; diff --git a/usr.bin/truss/i386-fbsd.c b/usr.bin/truss/i386-fbsd.c index d146ecd528bd..89879d2ff543 100644 --- a/usr.bin/truss/i386-fbsd.c +++ b/usr.bin/truss/i386-fbsd.c @@ -162,6 +162,7 @@ i386_syscall_entry(struct trussinfo *trussinfo, int nargs) if (fsc->name && (trussinfo->flags & FOLLOWFORKS) && (strcmp(fsc->name, "fork") == 0 || + strcmp(fsc->name, "pdfork") == 0 || strcmp(fsc->name, "rfork") == 0 || strcmp(fsc->name, "vfork") == 0)) trussinfo->curthread->in_fork = 1; diff --git a/usr.bin/truss/mips-fbsd.c b/usr.bin/truss/mips-fbsd.c index 6f5be66188a7..71e9efabdf31 100644 --- a/usr.bin/truss/mips-fbsd.c +++ b/usr.bin/truss/mips-fbsd.c @@ -155,6 +155,7 @@ mips_syscall_entry(struct trussinfo *trussinfo, int nargs) if (fsc->name && (trussinfo->flags & FOLLOWFORKS) && (strcmp(fsc->name, "fork") == 0 || + strcmp(fsc->name, "pdfork") == 0 || strcmp(fsc->name, "rfork") == 0 || strcmp(fsc->name, "vfork") == 0)) trussinfo->curthread->in_fork = 1; diff --git a/usr.bin/truss/powerpc-fbsd.c b/usr.bin/truss/powerpc-fbsd.c index 8cfb9ef75010..990da29c143e 100644 --- a/usr.bin/truss/powerpc-fbsd.c +++ b/usr.bin/truss/powerpc-fbsd.c @@ -169,6 +169,7 @@ powerpc_syscall_entry(struct trussinfo *trussinfo, int nargs) if (fsc->name && (trussinfo->flags & FOLLOWFORKS) && (strcmp(fsc->name, "fork") == 0 || + strcmp(fsc->name, "pdfork") == 0 || strcmp(fsc->name, "rfork") == 0 || strcmp(fsc->name, "vfork") == 0)) trussinfo->curthread->in_fork = 1; diff --git a/usr.bin/truss/powerpc64-fbsd.c b/usr.bin/truss/powerpc64-fbsd.c index 7147f8117a8d..9d5cbd9199b9 100644 --- a/usr.bin/truss/powerpc64-fbsd.c +++ b/usr.bin/truss/powerpc64-fbsd.c @@ -157,6 +157,7 @@ powerpc64_syscall_entry(struct trussinfo *trussinfo, int nargs) if (fsc->name && (trussinfo->flags & FOLLOWFORKS) && (strcmp(fsc->name, "fork") == 0 || + strcmp(fsc->name, "pdfork") == 0 || strcmp(fsc->name, "rfork") == 0 || strcmp(fsc->name, "vfork") == 0)) trussinfo->curthread->in_fork = 1; diff --git a/usr.bin/truss/sparc64-fbsd.c b/usr.bin/truss/sparc64-fbsd.c index 429fa2421d14..3c6de5fe2fa1 100644 --- a/usr.bin/truss/sparc64-fbsd.c +++ b/usr.bin/truss/sparc64-fbsd.c @@ -161,6 +161,7 @@ sparc64_syscall_entry(struct trussinfo *trussinfo, int nargs) if (fsc->name && (trussinfo->flags & FOLLOWFORKS) && (strcmp(fsc->name, "fork") == 0 || + strcmp(fsc->name, "pdfork") == 0 || strcmp(fsc->name, "rfork") == 0 || strcmp(fsc->name, "vfork") == 0)) trussinfo->curthread->in_fork = 1; |
