#1136 CURL_DISABLE_PROXY and USE_WINDOWS_SSPI: compile error

closed-fixed
libcurl (356)
5
2013-06-21
2012-08-24
Marcel Raad
No

I don't need proxy authentication, but SSL and I want to use the new SChannelAPI support, so I have defined both CURL_DISABLE_PROXY and USE_WINDOWS_SSPI. This results in a compile error in socks.c.
The line '#if !defined(CURL_DISABLE_PROXY) || defined(USE_WINDOWS_SSPI)' in socks.c should be changed to only '#if !defined(CURL_DISABLE_PROXY)' to resolve the error.

Discussion

  • Daniel Stenberg

    Daniel Stenberg - 2012-08-27

    What compiler error?

    And if you switch off the compiling of these functions, how can the socks_sspi.c source compile error free? It uses Curl_blockread_all() so I figure that file needs an adjusted #ifdef line as well?

     
  • Marcel Raad

    Marcel Raad - 2012-08-28

    The error is double definition of Curl_SOCKS4 and Curl_SOCKS5 (as CURLE_NOT_BUILT_IN in the header file and as a function in the .c file).

    socks_sspi.c compiles without errors when I compile libcurl as a static library as Curl_SOCKS5_gssapi_negotiate is never called in my application. But you're right, the #ifdef line in socks_sspi.c should also be changed to '#if (defined(USE_WINDOWS_SSPI) && !defined(CURL_DISABLE_PROXY))'.

     
  • Marcel Raad

    Marcel Raad - 2012-09-06

    Patch for socks.c and socks_sspi.c

     
    Attachments
  • Marcel Raad

    Marcel Raad - 2012-09-06

    I have attached a patch that fixes the problem.

     
  • Daniel Stenberg

    Daniel Stenberg - 2012-09-06
    • status: open --> closed-fixed
     
  • Daniel Stenberg

    Daniel Stenberg - 2012-09-06

    Thanks for the report, this problem is now fixed in the git repository.

    To try it out, you either checkout/update your git clone: http://curl.haxx.se/source.html

    or you try tomorrow's daily snapshot: http://curl.haxx.se/snapshots/

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks