Skip to content

Commit

Permalink
Adding "const" qualifier to arguments of date2my_decimal()
Browse files Browse the repository at this point in the history
and ErrConvString::ErrConvString(String *).
  • Loading branch information
Alexander Barkov committed Oct 22, 2015
1 parent bdc03e0 commit e498d32
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion sql/my_decimal.cc
Expand Up @@ -320,7 +320,7 @@ my_decimal *seconds2my_decimal(bool sign,
}


my_decimal *date2my_decimal(MYSQL_TIME *ltime, my_decimal *dec)
my_decimal *date2my_decimal(const MYSQL_TIME *ltime, my_decimal *dec)
{
longlong date= (ltime->year*100L + ltime->month)*100L + ltime->day;
if (ltime->time_type > MYSQL_TIMESTAMP_DATE)
Expand Down
2 changes: 1 addition & 1 deletion sql/my_decimal.h
Expand Up @@ -386,7 +386,7 @@ int string2my_decimal(uint mask, const String *str, my_decimal *d)
}


my_decimal *date2my_decimal(MYSQL_TIME *ltime, my_decimal *dec);
my_decimal *date2my_decimal(const MYSQL_TIME *ltime, my_decimal *dec);


#endif /*defined(MYSQL_SERVER) || defined(EMBEDDED_LIBRARY) */
Expand Down
2 changes: 1 addition & 1 deletion sql/sql_error.h
Expand Up @@ -567,7 +567,7 @@ class ErrConvString : public ErrConv
: ErrConv(), str(str_arg), len(len_arg), cs(cs_arg) {}
ErrConvString(const char *str_arg, CHARSET_INFO *cs_arg)
: ErrConv(), str(str_arg), len(strlen(str_arg)), cs(cs_arg) {}
ErrConvString(String *s)
ErrConvString(const String *s)
: ErrConv(), str(s->ptr()), len(s->length()), cs(s->charset()) {}
const char *ptr() const
{ return err_conv(err_buffer, sizeof(err_buffer), str, len, cs); }
Expand Down

0 comments on commit e498d32

Please sign in to comment.