Prefer "goto cleanup" over "do {... if (error) break; ... } while(0)" construction for error handling/jump (as suggested by Ruediger). Hence we can move backend->close = 1 (for mod_proxy_wstunnel) and proxy_run_detach_backend() (for mod_proxy_http2) in the cleanup fallback.