Removes useless space at the end of tickers
This commit is contained in:
@@ -42,8 +42,7 @@ void handleProvideErc20TokenInformation(uint8_t p1,
|
||||
}
|
||||
cx_hash((cx_hash_t *) &sha256, 0, workBuffer + offset, tickerLength, NULL, 0);
|
||||
memmove(token->ticker, workBuffer + offset, tickerLength);
|
||||
token->ticker[tickerLength] = ' ';
|
||||
token->ticker[tickerLength + 1] = '\0';
|
||||
token->ticker[tickerLength] = '\0';
|
||||
offset += tickerLength;
|
||||
dataLength -= tickerLength;
|
||||
|
||||
@@ -136,8 +135,7 @@ void handleProvideErc20TokenInformation(uint8_t p1,
|
||||
}
|
||||
cx_hash_sha256(workBuffer + offset, tickerLength + 20 + 4 + 4, hash, 32);
|
||||
memmove(token->ticker, workBuffer + offset, tickerLength);
|
||||
token->ticker[tickerLength] = ' ';
|
||||
token->ticker[tickerLength + 1] = '\0';
|
||||
token->ticker[tickerLength] = '\0';
|
||||
offset += tickerLength;
|
||||
dataLength -= tickerLength;
|
||||
memmove(token->address, workBuffer + offset, 20);
|
||||
|
||||
@@ -240,6 +240,7 @@ static void feesToString(uint256_t *rawFee, char *displayBuffer, uint32_t displa
|
||||
displayBuffer[tickerOffset] = feeTicker[tickerOffset];
|
||||
tickerOffset++;
|
||||
}
|
||||
if ((uint32_t) tickerOffset < displayBufferSize) displayBuffer[tickerOffset++] = ' ';
|
||||
while (G_io_apdu_buffer[i]) {
|
||||
if ((uint32_t) (tickerOffset) + i >= displayBufferSize) {
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user