From owner-freebsd-bugs Tue Apr 11 06:30:01 1995 Return-Path: bugs-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id GAA19723 for bugs-outgoing; Tue, 11 Apr 1995 06:30:01 -0700 Received: (from gnats@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id GAA19716 ; Tue, 11 Apr 1995 06:30:01 -0700 Date: Tue, 11 Apr 1995 06:30:01 -0700 Message-Id: <199504111330.GAA19716@freefall.cdrom.com> From: miff@spam.apana.org.au Reply-To: miff@spam.apana.org.au To: freebsd-bugs Subject: bin/334: -n option to strings does not work In-Reply-To: Your message of Tue, 11 Apr 1995 23:40:57 GMT <199504112340.XAA02102@spam.apana.org.au> Sender: bugs-owner@FreeBSD.org Precedence: bulk >Number: 334 >Category: bin >Synopsis: -n option to strings does not work >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs (FreeBSD bugs mailing list) >State: open >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Apr 11 06:30:00 1995 >Originator: michael smith >Organization: Genesis Software >Release: FreeBSD 2.0-RELEASE i386 >Environment: Any. >Description: The -n number option to /usr/bin/strings is not implemented correctly. Any attempt to specify a number generates an error. >How-To-Repeat: specify the -n option to strings : # strings -n 10 /kernel |more >Fix: In /usr/src/usr.bin/strings/strings.c, add the marked lines : + if (minlen < 1) + { if (minlen == -1) minlen = DEF_LEN; else { (void)fprintf(stderr, "strings: length less than 1\n"!); exit(1); } + } >Audit-Trail: >Unformatted: