Hi
Thanks for your help
I did as suggested by you.
Please not that I do not get a crash when I do a package require. I get a
crash when I am accessing one of our java applications using tclblend. the
java application works fine when it is working standalone and does not give
exceptions or errors.
If you need any more information, I will be happy to provide you with it.
I built the tcl8.0.5 with the --enable-symbols and then rebuilt
tclblend1.2.5 and jdk1.1.8 on Solaris 2.6.
I brought up jtclsh on one xterm and attached its pid to gdb in another
window as suggested.
when I attach the process to gdb, I get the following output
Attaching to process 3232
Reading symbols from /usr/test/tools/local/tcl8.0/lib/libtcl8.0g.so...done.
Reading symbols from /usr/lib/libdl.so.1...done.
Reading symbols from /usr/lib/libsocket.so.1...done.
Reading symbols from /usr/lib/libnsl.so.1...done.
Reading symbols from /usr/lib/libm.so.1...done.
Reading symbols from /usr/lib/libc.so.1...done.
Reading symbols from /usr/lib/libmp.so.2...done.
Reading symbols from /usr/platform/SUNW,Ultra-2/lib/libc_psr.so.1...done.
Reading symbols from /usr/test/tools/local/tcl8.0/lib/libtclblend.so...done.
Reading symbols from /usr/lib/libthread.so.1...done.
Reading symbols from
/usr/test/tools/vendor/jdk1.1.8/lib/sparc/native_threads/libjava.so...
done.
0xefab8598 in _read ()
I do the following operations in jtclsh. The phonetest is one of our
applications which we have written.
set res [java::new phonetest.ResManager]
set object1 [java::new java.lang.String "phonetest.phone.gsm.GSMPhone"]
set interface1 [java::new java.lang.String "EMMI"]
set socket1 [java::new java.lang.String "socket 136.182.32.237 7020"]
set config [java::new java.util.Properties]
$config put $interface1 $socket1
set phone [$res createPTFObject 1 $object1 $config]
set phone [java::cast phonetest.phone.gsm.GSMPhone $phone]
$phone open $config
Uptill this point, everything works fine
It is on this line that I get the crash
$phone close
At this point in the gdb window, I get the following
Program received signal SIGUSR1, User defined signal 1.
0xefb534d4 in __sigprocmask ()
Then I did a bt, here's the output for that
#0 0xefb534d4 in __sigprocmask ()
#1 0xefb4b070 in _resetsig ()
#2 0xefb4a934 in _sigon ()
#3 0xefb4620c in _ti_cond_timedwait ()
#4 0xefa17f9c in condvarTimedWait ()
#5 0xefa15ddc in sysMonitorWait ()
#6 0xefa02534 in monitorWait ()
#7 0xefa0a930 in threadSleep ()
#8 0xef9de7bc in Java_java_lang_Thread_sleep_stub ()
#9 0xef9dc69c in invokeNativeMethod ()
#10 0xefa19ed8 in notJavaInvocation ()
#11 0xef9ee3ec in do_execute_java_method_vararg ()
#12 0xef9eda90 in execute_java_dynamic_method ()
#13 0xefa09f1c in ThreadRT0 ()
#14 0xefa164dc in _start ()
I appreciate any help.thanks
Suvarna
>From: Moses DeJong <[EMAIL PROTECTED]>
>To: [EMAIL PROTECTED]
>Subject: [Tcl Java] Re: [Tcl Java] tclblend -segmentation fault
>Date: Mon, 22 Nov 1999 10:13:55 -0600 (CST)
>
>On Mon, 22 Nov 1999, Suvarna Ayyagari wrote:
>
> >
> > Hi,
>
>Humm, Solaris 2.6 is the 64 bit version of the OS right? I have
>yet to run Tcl Blend on a 64 bit OS.
>
> > I have installed tclblend1.2.5. the installation went fine. I built it
>on
> > Solaris 2.6 with JDK 1.1.8 with native threads and Tcl8.0.5.
> >
> > I used it from this area and I had no problems using it anytime.
>
>Is the production box the same version of Solaris? If not this might
>be a 32/64 bit mismatch problem.
>
> > I now wanted to install it in our prod area. the installation went fine.
>But
> > when I use this version, in one of the scripts which passed earlier, I
>get a
> > Segmentation fault now.
>
>Perhaps you ftped the file and forgot to turn binary mode on. I make
>that mistake a lot. If you just moved the file from one system to
>another the size of the file should not change.
>
> > I checked the size of the libtclblend.so (the one which gave me no
>problems
> > and the one which is giving me problems) in both directories. They are
> > different though I built it with the same tclblend and jdk on the same
> > operating system.
>
>Configure and compile Tcl with --enable-symbols. This will add debug
>symbols to Tcl. After doing that, configure Tcl Blend again and recompile
>Tcl Blend. Tcl Blend will notice that Tcl was compiled with symbols
>and it will also add debug symbols. The only thing to watch out for
>is that the native compiler on Solaris (cc) does not actually add
>debug symbols unless you pass the -g and -xs option to the compiler.
>gcc or egcs will add debug symbols with the -g flag. Now that you
>have debug symbols fire up tclblend using the jtclsh shell script
>and type pid to get the process id. Now go to a different xterm,
>start up gdb and attach it to the Tcl process (like so "gdb TCLPATH pid").
>After gdb starts up type "cont" at the gdb command prompt to keep
>running your Tcl shell. Now switch back to the Tcl shell and type
>"package require java" into the shell. If it crashes, you should be
>able to see where it crashed in the gdb window. You should be able
>to get a stack trace at the point where it crashed by typing "bt"
>at the gdb prompt.
>
> > How do I debug this?
>
>The jtclsh script installed when you build Tcl Blend should set
>the LD_LIBRARY_PATH and CLASSPATH env vars for you. You might
>also want to check the rld linking of libtclblend.so by typing
>"ldd libtclblend.so" at the command line.
>
>I hope that helps
>Mo DeJong
>
> > Now when I do a package require java, the Tclblend which is in the
> > LD_LIBRARY_PATH is picked up right?
>
>----------------------------------------------------------------
>The TclJava mailing list is sponsored by Scriptics Corporation.
>To subscribe: send mail to [EMAIL PROTECTED]
> with the word SUBSCRIBE as the subject.
>To unsubscribe: send mail to [EMAIL PROTECTED]
> with the word UNSUBSCRIBE as the subject.
>To send to the list, send email to '[EMAIL PROTECTED]'.
>
>
______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com
----------------------------------------------------------------
The TclJava mailing list is sponsored by Scriptics Corporation.
To subscribe: send mail to [EMAIL PROTECTED]
with the word SUBSCRIBE as the subject.
To unsubscribe: send mail to [EMAIL PROTECTED]
with the word UNSUBSCRIBE as the subject.
To send to the list, send email to '[EMAIL PROTECTED]'.