CLEANUP: stconn: Move SE flags set by app layer at the end of the bitfield
authorChristopher Faulet <cfaulet@haproxy.com>
Wed, 14 Feb 2024 13:52:24 +0000 (14:52 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 14 Feb 2024 15:39:46 +0000 (16:39 +0100)
To fix a bug, some SE flags must be added or renamed. To avoid mixing flags
set by the endpoint and flags set by the app, the second set of flags are
moved at the end of the bitfield, leaving the holes on the middle.

(cherry picked from commit 8cfc11f46188118d9b714b9e4e8dd2b44be18c3d)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>

include/haproxy/stconn-t.h

index 30f468a..380a388 100644 (file)
@@ -95,15 +95,16 @@ enum se_flags {
        /* following flags are supposed to be set by the app layer and read by
         * the endpoint :
         */
-       SE_FL_WAIT_FOR_HS   = 0x00400000,  /* This stream is waiting for handhskae */
-       SE_FL_KILL_CONN     = 0x00800000,  /* must kill the connection when the SC closes */
-       SE_FL_WAIT_DATA     = 0x01000000,  /* stream endpoint cannot work without more data from the stream's output */
-       SE_FL_WONT_CONSUME  = 0x02000000,  /* stream endpoint will not consume more data */
-       SE_FL_HAVE_NO_DATA  = 0x04000000,  /* the endpoint has no more data to deliver to the stream */
-       /* unused             0x08000000,*/
-       /* unused             0x10000000,*/
-       /* unused             0x20000000,*/
-       SE_FL_APPLET_NEED_CONN = 0x40000000,  /* applet is waiting for the other side to (fail to) connect */
+       /* unused             0x00400000,*/
+       /* unused             0x00800000,*/
+       /* unused             0x01000000,*/
+       /* unused             0x02000000,*/
+       SE_FL_WAIT_FOR_HS   = 0x04000000,  /* This stream is waiting for handhskae */
+       SE_FL_KILL_CONN     = 0x08000000,  /* must kill the connection when the SC closes */
+       SE_FL_WAIT_DATA     = 0x10000000,  /* stream endpoint cannot work without more data from the stream's output */
+       SE_FL_WONT_CONSUME  = 0x20000000,  /* stream endpoint will not consume more data */
+       SE_FL_HAVE_NO_DATA  = 0x40000000,  /* the endpoint has no more data to deliver to the stream */
+       SE_FL_APPLET_NEED_CONN = 0x80000000,  /* applet is waiting for the other side to (fail to) connect */
 };
 
 /* This function is used to report flags in debugging tools. Please reflect