]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
MINOR: ist: Add a function to retrieve the ist pointer
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 21 Apr 2020 08:46:43 +0000 (10:46 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Mon, 27 Apr 2020 08:46:28 +0000 (10:46 +0200)
There is already the istlen() function to get the ist length. Now, it is
possible to call istptr() to get the ist pointer.

include/common/ist.h

index 68c83ffa0e098c3e75b5f6ebc8da3fbc99a84887..2b5178f8c072324996feac25b33e5992c70859d8 100644 (file)
@@ -211,6 +211,12 @@ static inline char *ist0(struct ist ist)
        return ist.ptr;
 }
 
+/* returns the pointer of the string */
+static inline char *istptr(const struct ist ist)
+{
+       return ist.ptr;
+}
+
 /* returns the length of the string */
 static inline size_t istlen(const struct ist ist)
 {