libcurl - dll error on 32bit but not 64bit

牧云@^-^@ 提交于 2019-12-12 19:55:32

问题


This is a new thread started from post (link).

I have used the suggested curl library (link) for building libcurl into my dll. I link in libcurl_imp.lib and have created library routines for calling the curl methods. This all works a treat - BUT ONLY ON A 64BIT MACHINE? - if I try to run the same dll/binary app on a 32bit XP machine it just dumps out immediately. In fact all my applications abort - and they make no reference to my new library routines, they just use the dll. It seems that because I build in the cURL calls into my dll it immediately aborts the spawned process– I just get –

1 + Done(134) testapp

5656 Abort testapp

I have a printf statement immediately after main but I get no output on the command line.

I then removed all my new library functions from the dll apart from one, and in this all I do is –

CURLcode res = curl_global_init(CURL_GLOBAL_DEFAULT);

This one line causes all my apps to fail on 32bit when built into my dll – comment it out and they all work.

As stated, the same dll/binary works fine on my 64bit machine. The 64bit machine has the same curllib.dll runtime as the one on my 32bit machine.

For info, my build machine is 32bit, we have productions machines that are both 32 and 64 bit.

来源:https://stackoverflow.com/questions/12493300/libcurl-dll-error-on-32bit-but-not-64bit

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!