Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com Message-ID: <19990715224321.24409.qmail@hotmail.com> X-Originating-IP: [212.52.67.147] From: "Emanuele ALIBERTI" To: rbresner AT olf DOT com, cygwin AT sourceware DOT cygnus DOT com Subject: Re: More DLL fun! [fwd: ] Date: Thu, 15 Jul 1999 15:43:20 PDT Mime-Version: 1.0 Content-Type: text/plain; format=flowed > > I am trying to compare 2 pointers to functions. > > All I am looking for is if they match or not. > > The pointers are to a function. > > The function is in a DLL, and the first place to get the > > function pointer is in an exe. > > The following is kind of a code sample (kind of but not really). The behaviour is correct. I suppose you use an import library to call the DLL. The import library has stubs for each function the DLL exports and what you pass is the client process stub's address (the only known at link time). That is why your two pointers never match. You must explicitly get the relocated address of the function in the DLL by calling KERNEL32.GetProcAddress. ______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com