summaryrefslogtreecommitdiff
path: root/sql/sql_string.h
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2019-09-06 17:16:40 +0300
committerMarko Mäkelä <marko.makela@mariadb.com>2019-09-06 17:16:40 +0300
commit4081b7b27a40df6244e0525885cf70e48b7b35bc (patch)
treee9e6199730603d05090e0550e023e92c7a32f88d /sql/sql_string.h
parent780d2bb8a7eca4fdbdf70fbd51c0bdbae5b0057e (diff)
parent244f0e6dd815b388282c15db4fe7f15533f4c8fc (diff)
downloadmariadb-git-4081b7b27a40df6244e0525885cf70e48b7b35bc.tar.gz
Merge 10.4 into 10.5
Diffstat (limited to 'sql/sql_string.h')
-rw-r--r--sql/sql_string.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/sql/sql_string.h b/sql/sql_string.h
index 1eac2200625..deff81f3333 100644
--- a/sql/sql_string.h
+++ b/sql/sql_string.h
@@ -149,6 +149,10 @@ public:
{
return m_charset->cset->numchars(m_charset, str, end);
}
+ size_t lengthsp(const char *str, size_t length) const
+ {
+ return m_charset->cset->lengthsp(m_charset, str, length);
+ }
size_t charpos(const char *str, const char *end, size_t pos) const
{
return m_charset->cset->charpos(m_charset, str, end, pos);
@@ -929,6 +933,10 @@ public:
return (int) i;
return (int) Charset::charpos(ptr() + offset, end(), (size_t) i);
}
+ size_t lengthsp() const
+ {
+ return Charset::lengthsp(Ptr, str_length);
+ }
void print(String *to) const;
void print_with_conversion(String *to, CHARSET_INFO *cs) const;