Archives
D Programming
DD.gnu digitalmars.D digitalmars.D.bugs digitalmars.D.dtl digitalmars.D.ide digitalmars.D.dwt digitalmars.D.announce digitalmars.D.learn digitalmars.D.debugger C/C++ Programming
c++c++.announce c++.atl c++.beta c++.chat c++.command-line c++.dos c++.dos.16-bits c++.dos.32-bits c++.idde c++.mfc c++.rtl c++.stl c++.stl.hp c++.stl.port c++.stl.sgi c++.stlsoft c++.windows c++.windows.16-bits c++.windows.32-bits c++.wxwindows digitalmars.empire digitalmars.DMDScript electronics |
c++ - dmc problem
Hi All, First of all, my question is about the C language (and the dmc compiler). I have a static library that has functions using fprintf's, fopens inside. This library is then linked to a DLL (the DLL will be used from within the lua scripting language). Anyways, if I try to fopen a file to write, it hangs at that point. Can we use fopen, printf (standard C functions) from within a DLL? Are there any commadn line switched that we can use (I am using -mn when compiling). Dec 21 2007
Hi again, I have tries some other thing too... I have written a simple DLL with a simple function. This function just calls printf with a message. I am using LoadLibrary, GetProcAddress to get to the function in the main () function. If I leave the printf in the DLL function it hangs at that point. If I remove that from the function, it will call that function and the function returns (does not hang in that DLL function). Regards, rd. Dec 21 2007
rd skrev:Hi again, I have tries some other thing too... I have written a simple DLL with a simple function. This function just calls printf with a message. I am using LoadLibrary, GetProcAddress to get to the function in the main () function. If I leave the printf in the DLL function it hangs at that point. If I remove that from the function, it will call that function and the function returns (does not hang in that DLL function). Dec 21 2007
Hi again, I thank you for your reply. I was assuming that a DllMain function was suplied, when not given. Now it is working. Regards, rd Dec 23 2007
|