mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
MDEV-19955 make argument of handler::ha_write_row() const
MDEV-19486 and one more similar bug appeared because handler::write_row() interface welcomes to modify buffer by storage engine. But callers are not ready for that thus bugs are possible in future. handler::write_row(): handler::ha_write_row(): make argument const
This commit is contained in:
@ -3238,7 +3238,7 @@ public:
|
||||
and delete_row() below.
|
||||
*/
|
||||
int ha_external_lock(THD *thd, int lock_type);
|
||||
int ha_write_row(uchar * buf);
|
||||
int ha_write_row(const uchar * buf);
|
||||
int ha_update_row(const uchar * old_data, const uchar * new_data);
|
||||
int ha_delete_row(const uchar * buf);
|
||||
void ha_release_auto_increment();
|
||||
@ -4548,7 +4548,7 @@ private:
|
||||
*/
|
||||
virtual int rnd_init(bool scan)= 0;
|
||||
virtual int rnd_end() { return 0; }
|
||||
virtual int write_row(uchar *buf __attribute__((unused)))
|
||||
virtual int write_row(const uchar *buf __attribute__((unused)))
|
||||
{
|
||||
return HA_ERR_WRONG_COMMAND;
|
||||
}
|
||||
@ -4571,7 +4571,7 @@ private:
|
||||
Optimized function for updating the first row. Only used by sequence
|
||||
tables
|
||||
*/
|
||||
virtual int update_first_row(uchar *new_data);
|
||||
virtual int update_first_row(const uchar *new_data);
|
||||
|
||||
virtual int delete_row(const uchar *buf __attribute__((unused)))
|
||||
{
|
||||
|
Reference in New Issue
Block a user