Article View: microsoft.public.vc.language
Article #25Problem with mixing #pragma options
From: Knoppen
Date: Fri, 25 May 2001 17:08
Date: Fri, 25 May 2001 17:08
35 lines
3137 bytes
3137 bytes
Hi I hope some one out there can help me with this one. My problem is that I want to create a dll that is compatible with the lame interface (lame_enc.dll). The dll I'm writing is a Fraunhofer encoder which uses different pack opitions. In the interface I have, the functions I have exported are defined using the same pragma pack option as the lame interface. Yet I can not import the functions correct if the functions in the dll. I know it is the parameters that are the cause of error. Of curse I use the same calling conventions in the exported dll functions as for those I import in my Delphi program (__cdecl for C++ and cdecl for delphi). The library included in the DLL (a lib file linked in to the dll) is probably made using Visual C++ compiler and C source files. I use C++ since I use some classes in the dll. Every global pointer, object is created dynamically by a function I call so I know the creation of the object used are correct. If I include the source files for the dll in an executable every thing is in order. Therefor I know there ain't now error in the dynamic memory creation or deletion, no error in the function calls. The error only appears in the DLL. Are there any special rules for #pragma pack option in VC++ when I create a DLL. Lars Rosenberg Lars@RosoftEngineering.com -- Lars Rosenberg CEO of Rosoft Engineering, Karlstad - Sweden Email: Lars@RosoftEngineering.com Homepage: http://www.RosoftEngineering.com/ ------------------------------------------------ This email is subject to copyright and is intended only for the person(s) named. You may not disclose the contents of this email to other person(s) or take copies of it without the permission of the author.
Technical Details
Message-ID:
<8kwP6.12427$sk3.3379666@newsb.telia.net>Path:
arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!isdnet!newsfeed.icl.net!news.algonet.se!algonet!news-stob.telia.net!news-sto.telia.net!194.22.194.4.MISMATCH!masternews.telia.net.!newsb.telia.net.POSTED!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f8256,a10bbee398ae73f0,start X-Google-Attributes: gidf8256,public X-Google-Thread: 1043cf,a10bbee398ae73f0,start X-Google-Attributes: gid1043cf,public X-Google-Thread: f7a51,f049c3de9453230a X-Google-Attributes: gidf7a51,public X-Google-Thread: 10545b,a10bbee398ae73f0,start X-Google-Attributes: gid10545b,public X-Google-ArrivalTime: 2001-05-25 10:32:45 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!isdnet!newsfeed.icl.net!news.algonet.se!algonet!news-stob.telia.net!news-sto.telia.net!194.22.194.4.MISMATCH!masternews.telia.net.!newsb.telia.net.POSTED!not-for-mail From: "Knoppen" <lars@karlstad.mail.telia.com> Newsgroups: microsoft.public.vc.language,borland.public.delphi.thirdparty-tools,borland.public.delphi.objectpascal,borland.public.delphi.ide Subject: Problem with mixing #pragma options Lines: 39 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 Message-ID: <8kwP6.12427$sk3.3379666@newsb.telia.net> Date: Fri, 25 May 2001 17:08:20 GMT NNTP-Posting-Host: 213.66.128.39 X-Complaints-To: abuse@telia.com X-Trace: newsb.telia.net 990810500 213.66.128.39 (Fri, 25 May 2001 19:08:20 CEST) NNTP-Posting-Date: Fri, 25 May 2001 19:08:20 CEST Organization: Telia Internet