Skip to content

http2: fix runtime warnings when request fails due to IO error

Carlos Garcia Campos requested to merge carlosgc/http2-warnings-on-io-error into master

(get:18601): libsoup-WARNING **: 11:25:03.814: (../libsoup/soup-session.c:318):soup_session_dispose: runtime check failed: (soup_connection_manager_get_num_conns (priv->conn_manager) == 0)

(get:18601): libsoup-WARNING **: 11:25:03.814: (../libsoup/soup-connection-manager.c:78):soup_host_free: runtime check failed: (host->conns == NULL)

This happens because we increase the in use counter of the connection when RST_STREAM message is sent, that is decreased when the frame is actually sent. In case of IO error, like socket timeout, we fail to send the RST_STREAM frame, and the in use counter of the connection is not decreased. We now process all pending closed messages when a frame fails to be sent due to session being closed.

Merge request reports