You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cargo should exit without error. This worked with libcurl-7.63.0 but fails since fb445a1
Here is a backtrace:
#0 0x00007ffff7e21127 in h2_session_send () from /lib/libcurl.so.4
#1 0x00007ffff7e2195a in h2_process_pending_input () from /lib/libcurl.so.4
#2 0x00007ffff7e22b79 in http2_conncheck () from /lib/libcurl.so.4
#3 0x00007ffff7df280b in extract_if_dead () from /lib/libcurl.so.4
#4 0x00007ffff7df679c in Curl_connect () from /lib/libcurl.so.4
#5 0x00007ffff7e06b87 in multi_runsingle () from /lib/libcurl.so.4
#6 0x00007ffff7e07f29 in curl_multi_perform () from /lib/libcurl.so.4
#7 0x0000555555b85bd7 in curl::multi::Multi::perform ()
#8 0x000055555599adcb in <std::thread::local::LocalKey<T>>::with ()
#9 0x00005555556867a5 in cargo::core::package::Downloads::wait ()
#10 0x0000555555780e91 in cargo::core::compiler::context::unit_dependencies::build_unit_dependencies ()
#11 0x00005555558dda0d in cargo::core::compiler::context::Context::prepare_units ()
#12 0x00005555558dade8 in cargo::core::compiler::context::Context::compile ()
#13 0x0000555555690416 in cargo::ops::cargo_compile::compile_ws ()
#14 0x000055555563cb83 in cargo::ops::cargo_install::install_one ()
#15 0x0000555555637941 in cargo::ops::cargo_install::install ()
#16 0x00005555555d4f6b in cargo::commands::install::exec ()
#17 0x00005555555ca9d8 in cargo::cli::main ()
#18 0x00005555555fefec in cargo::main ()
#19 0x00005555555f6983 in std::rt::lang_start::{{closure}} ()
#20 0x0000555555c080a3 in std::panicking::try::do_call ()
#21 0x0000555555c1903a in __rust_maybe_catch_panic ()
#22 0x0000555555bf83dc in std::rt::lang_start_internal ()
#23 0x00005555556013e5 in main ()
Can we reproduce this in any way with just libcurl? Can you re-run your crashing case with a debug-enabled libcurl so that we get symbols/variables too, maybe we can suggest some debugging points or checks to do as well?
Can you try and see if this patch makes any difference? When the http2 connection is checked it now uses its conn->data pointer, but I think it might not be valid anymore here. We should set it explicitly to the one in use when the check is asked for.
--- a/lib/url.c+++ b/lib/url.c@@ -962,10 +962,11 @@ static bool extract_if_dead(struct connectdata *conn,
bool dead;
if(conn->handler->connection_check) {
/* The protocol has a special method for checking the state of the
connection. Use it to check if the connection is dead. */
unsigned int state;
+ conn->data = data; /* use this transfer for now */
state = conn->handler->connection_check(conn, CONNCHECK_ISDEAD);
dead = (state & CONNRESULT_DEAD);
}
else {
/* Use the general method for determining the death of a connection */
Activity
bagder commentedon Feb 8, 2019
Can we reproduce this in any way with just libcurl? Can you re-run your crashing case with a debug-enabled libcurl so that we get symbols/variables too, maybe we can suggest some debugging points or checks to do as well?
jnbr commentedon Feb 9, 2019
This is with current
HEAD(b3cc801):will try
bagder commentedon Feb 10, 2019
Can you try and see if this patch makes any difference? When the http2 connection is checked it now uses its
conn->datapointer, but I think it might not be valid anymore here. We should set it explicitly to the one in use when the check is asked for.jnbr commentedon Feb 10, 2019
Yes, this fixes it. I cannot reproduce the segfault anymore with the patch applied.
connection_check: set ->data to the transfer doing the check
jnbr commentedon Feb 11, 2019
Thanks a lot!
vendor: update curl to master to fix curl/curl#3541