Fixed more zchar / string copy errors

Resolves #224
This commit is contained in:
Raphael Coeffic
2021-06-16 18:00:42 +02:00
parent da8e1022a0
commit d10563d08b
4 changed files with 13 additions and 12 deletions
+1 -1
View File
@@ -143,7 +143,7 @@ void writeHeader()
TelemetrySensor & sensor = g_model.telemetrySensors[i];
if (sensor.logs) {
memset(label, 0, sizeof(label));
zchar2str(label, sensor.label, TELEM_LABEL_LEN);
strncpy(label, sensor.label, TELEM_LABEL_LEN);
uint8_t unit = sensor.unit;
if (unit == UNIT_CELLS ) unit = UNIT_VOLTS;
if (UNIT_RAW < unit && unit < UNIT_FIRST_VIRTUAL) {