diff options
Diffstat (limited to 'sql/sql_string.h')
-rw-r--r-- | sql/sql_string.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/sql/sql_string.h b/sql/sql_string.h index c9eaf924e4d..ca6bd2f0116 100644 --- a/sql/sql_string.h +++ b/sql/sql_string.h @@ -176,6 +176,18 @@ public: { return set_int((longlong)num, true, cs); } bool set_real(double num,uint decimals, CHARSET_INFO *cs); + /* Move handling of buffer from some other object to String */ + void reassociate(char *ptr, uint32 length, uint32 alloced_length, + CHARSET_INFO *cs) + { + free(); + Ptr= ptr; + str_length= length; + Alloced_length= alloced_length; + str_charset= cs; + alloced= ptr != 0; + } + /* PMG 2004.11.12 This is a method that works the same as perl's "chop". It simply |