Date: Mon, 2 Oct 2000 15:25:40 -0400 (EDT) From: ak03@gte.com To: FreeBSD-gnats-submit@freebsd.org Subject: ports/21705: CSCOPE writes incorrect offset into index file Message-ID: <200010021925.e92JPeA19141@h132-197-97-45.gte.com>
next in thread | raw e-mail | index | archive | help
>Number: 21705 >Category: ports >Synopsis: CSCOPE writes incorrect offset into index file >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Oct 02 12:30:01 PDT 2000 >Closed-Date: >Last-Modified: >Originator: Alexander Kabaev >Release: FreeBSD 5.0-CURRENT i386 >Organization: >Environment: Ports tree cvsupped on Oct 2 2000, FreeBSD 5.0-CURRENT (not relevant) >Description: Due to the fact, that FreeBSD fputs does not return exact number of bytes written, wrong value for 'tailerofset' is getting written into the cross-reference file. That makes it impossible to reuse index file when running cscope under cbrowser control, for instance. Cbrowser runs cscope with the command which looks like: cscope -dl -f cscope.out where -d instructs cscope not to rebuild index file and assume it is up-to-date. While trying to reopen pre-existing data file cscope seeks at incorrect offset and then fails with an error message. >How-To-Repeat: Run cscope with above command line and watch it fail. >Fix: Add attached file to the patches directory. --- src/constants.h.orig Mon Oct 2 14:36:07 2000 +++ src/constants.h Mon Oct 2 14:37:09 2000 @@ -43,7 +43,7 @@ /* database output macros that update its offset */ #define dbputc(c) (++dboffset, (void) putc(c, newrefs)) -#if Linux || BSD && !sun +#if Linux || __FreeBSD__ || BSD && !sun #define dbfputs(s) (dboffset += strlen(s), fputs(s, newrefs)) #else #define dbfputs(s) (dboffset += fputs(s, newrefs)) >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200010021925.e92JPeA19141>