Fix potential buffer overflow in LCD messages
This commit is contained in:
parent
6a3d82e492
commit
d84231f2d5
|
|
@ -2789,7 +2789,8 @@ static bool autotune(int16_t cal_temp)
|
||||||
{
|
{
|
||||||
uint16_t samples;
|
uint16_t samples;
|
||||||
float e;
|
float e;
|
||||||
char tm_message[20];
|
char tm_message[LCD_WIDTH+1];
|
||||||
|
|
||||||
// bootstrap C/R values without fan
|
// bootstrap C/R values without fan
|
||||||
set_fan_speed(0);
|
set_fan_speed(0);
|
||||||
|
|
||||||
|
|
@ -2886,7 +2887,7 @@ static bool autotune(int16_t cal_temp)
|
||||||
|
|
||||||
void temp_model_autotune(int16_t temp, bool selftest)
|
void temp_model_autotune(int16_t temp, bool selftest)
|
||||||
{
|
{
|
||||||
char tm_message[20];
|
char tm_message[LCD_WIDTH+1];
|
||||||
if(moves_planned() || printer_active()) {
|
if(moves_planned() || printer_active()) {
|
||||||
sprintf_P(tm_message, PSTR("TM: Cal. NOT IDLE"));
|
sprintf_P(tm_message, PSTR("TM: Cal. NOT IDLE"));
|
||||||
lcd_setstatus_serial(tm_message);
|
lcd_setstatus_serial(tm_message);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue