Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 30 Sep 1995 20:18:32 +0100 (MET)
From:      Ollivier Robert <roberto@keltia.freenix.fr>
To:        freebsd-current@FreeBSD.ORG (FreeBSD Current Users' list)
Subject:   tn3270/tools/mkastosc is dumping core
Message-ID:  <199509301918.UAA01073@keltia.freenix.fr>

next in thread | raw e-mail | index | archive | help
I get a SIGV each time I try to make depend in usr.bin/tn3270. 

It happens at this line :

265 [20:10] roberto@keltia:tools/mkastosc> gdb ./mkastosc
GDB is free software and you are welcome to distribute copies of it
 under certain conditions; type "show copying" to see the conditions.
There is absolutely no warranty for GDB; type "show warranty" for details.
GDB 4.13 (i386-unknown-freebsd), 
Copyright 1994 Free Software Foundation, Inc...
(gdb) file mkastosc
Load new symbol table from "mkastosc"? (y or n) y
Reading symbols from mkastosc...done.
(gdb) run /work/tmp/tn3270/tn3270/../ctlr/hostctlr.h  /work/tmp/tn3270/tn3270/../ctlr/function.h < /work/tmp/tn3270/tn3270/../ctlr/unix.kbd  > astosc.OUT
Starting program: /work/tmp/tn3270/tools/mkastosc/mkastosc /work/tmp/tn3270/tn3270/../ctlr/hostctlr.h  /work/tmp/tn3270/tn3270/../ctlr/function.h < /work/tmp/tn3270/tn3270/../ctlr/unix.kbd  > astosc.OUT

Program received signal SIGSEGV, Segmentation fault.
main (argc=3, argv=0xefbfd45c) at mkastosc.c:145
145                     if ((Ph->name[i] != 0) &&
(gdb) print Ph
$1 = (struct Hits *) 0xa70000
(gdb) print Ph->name 
Error accessing memory address 0xa70024: Invalid argument.
(gdb) print i
$2 = 0
(gdb) print Ph->name|0]
syntax error
(gdb) print Ph->name[0]
Error accessing memory address 0xa70024: Invalid argument.

The offending line is this one :

                if ((Ph->name[i] != 0) &&
                        (Ph->name[i][0] == this->name[0]) &&
                        (strcmp(Ph->name[i], this->name) == 0)) {

Has anyone an idea about why it's getting a SEGV ? 

I have removed tn3270 from usr.bin/Makefile for now, it stops "make world".
-- 
Ollivier ROBERT    -=- The daemon is FREE! -=-    roberto@keltia.frmug.fr.net
   FreeBSD keltia.freenix.fr 2.2-CURRENT #2: Mon Sep 25 02:02:31 MET 1995



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199509301918.UAA01073>