delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/07/22/02:44:22

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <40FF61A4.5050308@luukku.com>
Date: Thu, 22 Jul 2004 09:41:40 +0300
From: Jani tiainen <redetin AT luukku DOT com>
User-Agent: Mozilla Thunderbird 0.7.1 (Windows/20040626)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: DLLs and LoadLibrary
References: <40FF4BA7 DOT 6010803 AT berezniker DOT com>
In-Reply-To: <40FF4BA7.6010803@berezniker.com>
X-IsSubscribed: yes

Vadim Berezniker wrote:

> I followed the FAQ and the various mailing list messages and was able to 
> build a dll that I can load with LoadLibrary.
> The code inside the DLL makes calls to code in other libraries and for 
> the most part this is okay.
> When I make calls to one library, everything is OK. As soon as I 
> uncomment one line which is simply a call to a function in another 
> library, the resulting DLL cannot be loaded with LoadLibrary.

There is various reasons why loading fails. If you get NULL from 
LoadLibrary call, use GetLastError to retrieve real reason for error.

BTW, where are you calling those LoadLibrary calls? It's unsafe (and not 
really recommended) to call them in DllMain.

-- 

Jani Tiainen


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


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