]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
CLEANUP: stconn: Don't expect to have no sedesc on detach
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 17 Jun 2022 07:39:59 +0000 (09:39 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 17 Jun 2022 11:25:02 +0000 (13:25 +0200)
The stream connector must always have a defined sedesc. So there is no
reason to test it when the stconn is detached from the endpoint.

src/stconn.c

index 02a8dc452d0ce20ab6fea79e4acb83ad7e1e351b..d69e68e5ff1ed8fe500d9eda782b22bb91a1d69e 100644 (file)
@@ -341,9 +341,6 @@ static void sc_detach_endp(struct stconn **scp)
        if (!sc)
                return;
 
-       if (!sc->sedesc)
-               goto reset_cs;
-
        if (sc_ep_test(sc, SE_FL_T_MUX)) {
                struct connection *conn = __sc_conn(sc);
                struct sedesc *sedesc = sc->sedesc;
@@ -385,7 +382,6 @@ static void sc_detach_endp(struct stconn **scp)
                sc_ep_set(sc, SE_FL_DETACHED);
        }
 
-  reset_cs:
        /* FIXME: Rest SC for now but must be reviewed. SC flags are only
         *        connection related for now but this will evolved
         */