delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin-developers/2001/06/10/10:59:15

Mailing-List: contact cygwin-developers-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-developers-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin-developers/>
List-Post: <mailto:cygwin-developers AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-developers-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-developers-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin-developers AT sources DOT redhat DOT com
Date: Sun, 10 Jun 2001 18:56:33 +0400
From: egor duda <deo AT logos-m DOT ru>
X-Mailer: The Bat! (v1.45) Personal
Reply-To: egor duda <cygwin-developers AT cygwin DOT com>
Organization: deo
X-Priority: 3 (Normal)
Message-ID: <23114413578.20010610185633@logos-m.ru>
To: Christopher Faylor <cygwin-developers AT cygwin DOT com>
Subject: Re: dll base address
In-reply-To: <20010610004015.D29231@redhat.com>
References: <001f01c0f0e6$72b8ec80$0200a8c0 AT lifelesswks>
<20010610004015 DOT D29231 AT redhat DOT com>
Mime-Version: 1.0

Hi!

Sunday, 10 June, 2001 Christopher Faylor cgf AT redhat DOT com wrote:

>>As you can see, cygwin1.dll has been loaded at 02561000. It seems to me
>>that if __cygwin_user_data is a non-relocatble variable, that we should
>>mark cygwin1.dll as non-relocatable.
>>
>>Thoughts?

CF> It's possible that this is just an artifact of faulty handling by gdb.
CF> I'm not aware of any reason for cygwin1.dll to be unrelocatable.

i believe it isn't. when fhandlers are passed between processes,
they're just copied as array of bytes. this includes their vtables. as
long as cygwin1.dll is loaded at equal base addresses, everything's
fine -- all vtables remain valid after copying. but if cygwin1.dll is
relocated in exec()ed process, first call to virtual method in
fhandler cause referencing invalid memory.

i hadn't found a way to access vtable in gcc, so i don't know an
elegant way to fix this.

Egor.            mailto:deo AT logos-m DOT ru ICQ 5165414 FidoNet 2:5020/496.19


- Raw text -


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