delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/01/07/12:41:57

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
X-Authentication-Warning: hp2.xraylith.wisc.edu: khan owned process doing -bs
Date: Fri, 7 Jan 2000 11:44:05 -0600 (CST)
From: Mumit Khan <khan AT NanoTech DOT Wisc DOT EDU>
To: "Dr. Schroeder, Klaus" <schroeder AT repas-aeg DOT de>
cc: cygwin AT sourceware DOT cygnus DOT com
Subject: Re: problem with JAVA and global constructors in dll
In-Reply-To: <3875F60E.D0321237@repas-aeg.de>
Message-ID: <Pine.HPP.3.96.1000107114027.1532Q-100000@hp2.xraylith.wisc.edu>
MIME-Version: 1.0

On Fri, 7 Jan 2000, Dr. Schroeder, Klaus wrote:

> I'm running a Java-application using native IO-routines from my.dll,
> which I built using the rules outlined by Mumit Kahn in his
> java-jni-examples. The example runs just fine including the calling of
> the global constructor, but using my own functions crashes with a
> segmentation violation in ioctl.
> 
> Using gdb and a cygwin1.dll-Version with symbols I found, that ioctl
> uses a global instance of class locker defined in debug.cc (locker __tn
> NO_COPY;).  This instance apparently was not initalized, which caused
> the segmentation violation.
> 
> My Question: Why are the global constructors of cygwin1.dll not called,
> when used in the above fashion? Is there a way to call them explicitly?

Global constructors are certainly called, but there are issues in Cygwin
itself that may cause this problem unless you're using the latest Cygwin
DLL (and using one of my patches that's not in the snapshot itself -- cgf
is evaluating it).

Linkname: (patch) enable signals in dynamically loaded Cygwin DLL
URL: http://sourceware.cygnus.com/ml/cygwin-developers/1999-12/msg00024.html

If you send me the code for JNI (hopefully a trimmed down case that shows
the bug), I'll take a look.

Regards,
Mumit



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019