Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo


#1377 Regression in 7.35.0 to (at least) 7.37.0 related to IPv6 (on Windows?)


My software uses libcurl as its socket layer via CURLOPT_CONNECT_ONLY. One user is reporting a regression connecting to http://stratum.f2pool.com:3333 (note, this is not a HTTP server) that we have isolated to 2d435c7fb5b7691e8ca1f3052e1eb5bcd8a4ea27 (trynextip: fix build for non-IPV6 capable systems). I am building libcurl with --enable-ipv6, but strangely enough, I don't think ENABLE_IPV6 is defined anywhere (lib/curl_config.h contains / #undef ENABLE_IPV6 /). The user in question does not have IPv6 on his (Windows XP) system, so I am guessing that somehow libcurl is simply never trying IPv4 in this case.


    • assigned_to: Daniel Stenberg
  • Thanks for your report.

    In this error case, do you know what 'firstfamily' is then? It seems it is something else than AF_INET ...

  • Luke-Jr

    I've confirmed that on the contrary, firstfamily=AF_INET. Also, the file is compiled withOUT ENABLE_IPV6 defined, despite --enable-ipv6 passed to configure...

  • 1) --enable-ipv6 is what configure does by default - it means it will check for IPv6 capable and working name resolver functions. The summary at the end of configure's run should tell you what it found. If ENABLE_IPV6 is not in lib/curl_config.h then configure failed to find such functions and build without using them. curl -V will then not list IPv6 as a feature.

    2) but with firstfamily=AF_INET, I don't see how the commit 2d435c7fb5b actually destroyed the logic. Can you?

    3) stratum.f2pool.com doesn't seem to resolve any AAAA records

    Which resolver backend are you using?

    I can't repeat this problem.

  • Luke-Jr

    1) The summary at the end shows " ipv6 support: enabled"

    2) Before the commit, firstfamily being AF_INET caused family to be AF_INET6. After, it is just AF_INET. I'm not familiar with what behaviour is expected/right here...

    3) It is an IPv4-only server.

    4) configure shows " resolver: default (--enable-ares / --enable-threaded-resolver)"

    I cannot repeat the problem either (but I don't have Windows).

  • Regarding (2), can you then explain why the code doesn't work? That seems very odd to me.

    The happy eyeballs code is there to try connecting using both IPv4 and IPv6 at the same time and go with the one that connected first.

    As nobody of us can repeat the problem nor understand why it happens, I'm not sure how to proceed with this!

    • status: open --> pending-needsinfo
    • labels: --> ipv6, windows build, regression
    • status: pending-needsinfo --> closed-later
  • As we lack info and can't figure it out this problem without that, I'm closing this report. If you figure out more details we can re-open this entry again in the future, or possibly file a new one.