HappenLee commented on code in PR #17970:
URL: https://github.com/apache/doris/pull/17970#discussion_r1145635638


##########
be/src/vec/common/string_ref.cpp:
##########
@@ -53,6 +53,13 @@ StringRef StringRef::max_string_val() {
     return StringRef((char*)(&StringRef::MAX_CHAR), 1);
 }
 
+bool StringRef::start_with(const char& ch) const {
+    return data[0] == ch;
+}
+bool StringRef::end_with(const char& ch) const {
+    return data[size - 1] == ch;

Review Comment:
   dangerous !!!! please check size when you try to access data mem



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to