X-From-Line: clanlib-devel-bounces+grumbel=gmx.net@clanlib.org Mon Sep 8 08:45:53 2003 Delivered-To: postmaster@penpen Received: from pop.gmx.net (213.165.64.20) by penpen with POP3 for ; 08 Sep 2003 08:45:53 -0000 Return-Path: X-Flags: 0000 Delivered-To: GMX delivery to grumbel@gmx.net Received: (qmail 2703 invoked by uid 65534); 8 Sep 2003 08:34:42 -0000 Received: from vacuum1.xentive.com (EHLO vacuum1.xentive.com) (195.249.47.163) by mx0.gmx.net (mx020-rz3) with SMTP; 08 Sep 2003 10:34:42 +0200 Received: (qmail 20748 invoked from network); 8 Sep 2003 08:34:42 -0000 Received: from unknown (HELO dark.clansoft.dk) (217.116.224.121) by 192.168.2.2 with RC4-SHA encrypted SMTP; 8 Sep 2003 08:34:42 -0000 Received: from dark.clansoft.dk ([127.0.0.1] ident=list) by dark.clansoft.dk with esmtp (Exim 4.22) id 19wH6h-00051c-RK for grumbel@gmx.net; Mon, 08 Sep 2003 10:10:43 +0200 Received: from mbn by dark.clansoft.dk with local (Exim 4.22) id 19wH6f-00051R-4t for clanlib-devel@clanlib.org; Mon, 08 Sep 2003 10:10:41 +0200 Date: Mon, 8 Sep 2003 10:10:41 +0200 From: Magnus Norddahl To: clanlib-devel@clanlib.org Subject: Re: [Clanlib-devel] Error when compiling ClanLib X-Gnus-Mail-Source: file:/home/ingo/.procmaildir/incoming Message-ID: <20030908081041.GA12095@dark.clansoft.dk> References: <3F5BC11C.6020602@student.rug.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <3F5BC11C.6020602@student.rug.nl> User-Agent: Mutt/1.5.4i X-BeenThere: clanlib-devel@clanlib.org X-Mailman-Version: 2.1.2 Precedence: list Reply-To: clanlib-devel@clanlib.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: clanlib-devel-bounces+grumbel=gmx.net@clanlib.org Errors-To: clanlib-devel-bounces+grumbel=gmx.net@clanlib.org X-GMX-Antivirus: -1 (not scanned, may not use virus scanner) X-GMX-Antispam: 0 (Mail was not recognized as spam) X-Spam-Status: No, hits=-4.5 required=5.0 tests=IN_REP_TO,QUOTED_EMAIL_TEXT,REFERENCES,REPLY_WITH_QUOTES, USER_AGENT_MUTT version=2.55 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) Status: RO X-Content-Length: 690 Lines: 27 Xref: penpen.localdomain ClanLib.Devel:6968 Quoting Bjørn Lindeijer (t.lindeijer@student.rug.nl): > Sources/Core/System/Win32/cl_library.cpp:60: invalid conversion from > `int (*)() > ' to `void*' Just looked at the MSDN docs for GetProcAddress, and yes, it returns a FARPROC which is a typedef for an int(*)(). I wonder why MSVC didnt even make a warning about this. :) Anyways, you solve the problem by simply adding a cast to a (void *): void *adr = (void *) GetProcAddress(handle,symbol.c_str()); I've committed a fix for this to cvs. -- Magnus Norddahl, Clansoft _______________________________________________ Clanlib-devel mailing list Clanlib-devel@clanlib.org http://clanlib.org/mailman/listinfo/clanlib-devel