From owner-freebsd-bugs Mon Apr 14 03:40:13 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id DAA02603 for bugs-outgoing; Mon, 14 Apr 1997 03:40:13 -0700 (PDT) Received: (from gnats@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id DAA02577; Mon, 14 Apr 1997 03:40:10 -0700 (PDT) Resent-Date: Mon, 14 Apr 1997 03:40:10 -0700 (PDT) Resent-Message-Id: <199704141040.DAA02577@freefall.freebsd.org> Resent-From: gnats (GNATS Management) Resent-To: freebsd-bugs Resent-Reply-To: FreeBSD-gnats@freefall.FreeBSD.org, dada@sbox.tu-graz.ac.at Received: from freepass.tu-graz.ac.at (freepass.tu-graz.ac.at [129.27.193.133]) by freefall.freebsd.org (8.8.5/8.8.5) with SMTP id DAA02103 for ; Mon, 14 Apr 1997 03:33:14 -0700 (PDT) Received: (from dada@localhost) by freepass.tu-graz.ac.at (8.6.11/8.6.9) id MAA14101; Mon, 14 Apr 1997 12:32:35 +0200 Message-Id: <199704141032.MAA14101@freepass.tu-graz.ac.at> Date: Mon, 14 Apr 1997 12:32:35 +0200 From: Martin Kammerhofer Reply-To: dada@sbox.tu-graz.ac.at To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.2 Subject: bin/3284: symorder(1): -t option does not work at all Sender: owner-bugs@freebsd.org X-Loop: FreeBSD.org Precedence: bulk >Number: 3284 >Category: bin >Synopsis: symorder(1): -t option doesnīt work at all >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Apr 14 03:40:09 PDT 1997 >Last-Modified: >Originator: Martin Kammerhofer >Organization: Graz University of Technology >Release: FreeBSD 2.2.1-RELEASE i386 >Environment: >Description: Option -t of symorder(1) doesnīt work. Furthermore if the table of excluded symbols specified by the -x command line option or the mandatory "symlist" overflow (static size SPACE) extra symbols are silently ignored! I didnīt fix the latter, only increased SPACE. >How-To-Repeat: cat >hello.c #include void main() { printf("Hello wonderful world\n"); } ^D cc -o hello hello.c ldd -v hello | grep a_syms echo start >start symorder -t start hello ldd -v hello | grep a_syms >Fix: --- /usr/src/usr.bin/symorder/symorder.c Fri Nov 3 19:27:18 1995 +++ ./symorder.c Thu Mar 27 13:26:56 1997 @@ -31,6 +31,8 @@ * SUCH DAMAGE. */ +/* $Id$ */ + #ifndef lint char copyright[] = "@(#) Copyright (c) 1980 The Regents of the University of California.\n\ @@ -55,7 +57,7 @@ #include #include -#define SPACE 500 +#define SPACE 0x2000 #define OKEXIT 0 #define NOTFOUNDEXIT 1 @@ -203,6 +205,7 @@ if (newstrings == NULL) error(NULL); t = newstrings; + i = symkept; for (symp = symtab; --i >= 0; symp++) { if (symp->n_un.n_strx == 0) continue; @@ -314,6 +317,8 @@ register char *nam; register int x; + if (small && inlist(p) == -1) + return (1); if (p->n_type & N_STAB || p->n_un.n_strx == 0) return (0); if (p->n_un.n_strx < sizeof(int) || p->n_un.n_strx >= strtabsize) >Audit-Trail: >Unformatted: