There was a known bug with cscope in that it violates its own naming
convention for the default versions of the 'in' and 'po' files--the
default names are 'cscope.in.out' and 'cscope.po.out', but if you use
the -f 'foo' option, you get 'foo.in' and 'foo.po' (so if you pass '-f
cscope.out' you get 'cscope.out.in', not 'cscope.in.out').
I submitted a patch for this a while ago, but it looks like I must have
missed a case (I've verified that the use case below causes a segfault
on my Linux box).
We could fix this case, but I'm actually more inclined to rip the whole
patch out and do the "right" thing--make cscope use
'cscope.out.[in|po]' as the default names, so there's no more mismatch
to hack around. I suggested this to Peter as my initial fix, but at
the time he was hesistant to much with it in case we disturbed any
users. Hans, now that you're the King what do you think?
Jason
--- Darlene Wong <darlenew@...> wrote:
> If a database is built with -q and -f but queried without the -f
> option,
> it segfaults in invflipname(). This occurs for me both on Linux and
> Solaris 2.6 machines.
>
> Here is the backtrace:
>
> Program received signal SIGSEGV, Segmentation fault.
> 0x805b684 in invflipname (invname=0x8096f80 "cscope.in.out",
> from=0x8099878 "cscope.in.out", to=0x8099886 "cscope.out.in")
> at invlib.c:519
> 519 *i++ = *to++;
> (cisco-5.0.8-gdb) bt
> #0 0x805b684 in invflipname (invname=0x8096f80 "cscope.in.out",
> from=0x8099878 "cscope.in.out", to=0x8099886 "cscope.out.in")
> at invlib.c:519
> #1 0x805b769 in invopen (invcntl=0x80b26c0,
> invname=0x8096f80 "cscope.in.out", invpost=0x8096f8e
> "cscope.po.out",
> stat=0) at invlib.c:540
> #2 0x804f38e in opendatabase () at build.c:161
> #3 0x805dbb9 in main (argc=0, argv=0xbfffe8a8) at main.c:551
> #4 0x42017589 in __libc_start_main () from /lib/i686/libc.so.6
>
> I can work around this by (of course) querying using -f, or by
> creating
> the following symlinks:
>
> cscope.in.out -> cscope.out.in
> cscope.po.out -> cscope.out.po
>
> Is this a known bug or shall I keep looking at it?
>
> thanks,
> Darlene Wong
> IOS Software Tools & Engineering Productivity
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by:
> Sybase ASE Linux Express Edition - download now for FREE
> LinuxWorld Reader's Choice Award Winner for best database on Linux.
> http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click
> _______________________________________________
> Cscope-devel mailing list
> Cscope-devel@...
> https://lists.sourceforge.net/lists/listinfo/cscope-devel
>
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
|