# HG changeset patch # User heinrichsweikamp # Date 1738673333 -3600 # Node ID e7cd7ffd1879c9c4637699fed4ed975aad6e6e2d # Parent 57b82ae999699fe8876957a9ce22f689f98af157 Add proper string termination and fix space. (mikeller) diff -r 57b82ae99969 -r e7cd7ffd1879 Discovery/Src/t7.c --- a/Discovery/Src/t7.c Thu Jan 30 21:26:38 2025 +0100 +++ b/Discovery/Src/t7.c Tue Feb 04 13:48:53 2025 +0100 @@ -2981,13 +2981,15 @@ if (isLoopMode(stateUsed->diveSettings.diveMode)) { textPointer = snprintf(TextR1, TEXTSIZE, "\a\001 %c%c ", TXT_2BYTE, TXT2BYTE_BailoutShort); textPointer += tHome_gas_writer(stateUsed->diveSettings.gas[actualBetterBailoutGasId()].oxygen_percentage, stateUsed->diveSettings.gas[actualBetterBailoutGasId()].helium_percentage, &TextR1[textPointer]); + TextR1[textPointer++] = '?'; TextR1[textPointer++] = ' '; - TextR1[textPointer++] = '?'; + TextR1[textPointer++] = 0; } else { textPointer = snprintf(TextR1, TEXTSIZE, "\a\001 %c%c %01.2f/", TXT_2BYTE, TXT2BYTE_LoopShort, stateUsed->diveSettings.setpoint[actualBetterSetpointId()].setpoint_cbar / 100.0); textPointer += tHome_gas_writer(stateUsed->diveSettings.gas[stateUsed->lifeData.lastDiluent_GasIdInSettings].oxygen_percentage, stateUsed->diveSettings.gas[stateUsed->lifeData.lastDiluent_GasIdInSettings].helium_percentage, &TextR1[textPointer]); + TextR1[textPointer++] = '?'; TextR1[textPointer++] = ' '; - TextR1[textPointer++] = '?'; + TextR1[textPointer++] = 0; } GFX_write_string_color(&FontT48, &t7c2, TextR1, 0, CLUT_WarningYellow); @@ -4921,6 +4923,7 @@ } return color; } + void t7_tick(void) { SSettings *settings = settingsGetPointer();