Skip to content

Commit

Permalink
Merge pull request #509 from LedgerHQ/cev/remove_unused_var
Browse files Browse the repository at this point in the history
Remove currentHeight unused var in nbgl_use_case
  • Loading branch information
cedelavergne-ledger authored Jan 24, 2024
2 parents 886d8f9 + a9d8362 commit 681c11d
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions lib_nbgl/src/nbgl_use_case.c
Original file line number Diff line number Diff line change
Expand Up @@ -774,16 +774,14 @@ uint8_t nbgl_useCaseGetNbTagValuesInPage(uint8_t nbPair
*/
uint8_t nbgl_useCaseGetNbPagesForTagValueList(const nbgl_layoutTagValueList_t *tagValueList)
{
uint8_t nbPages = 0;
uint8_t nbPairs = tagValueList->nbPairs;
uint8_t nbPairsInPage;
uint16_t currentHeight = 0;
uint8_t i = 0;
bool tooLongToFit;
uint8_t nbPages = 0;
uint8_t nbPairs = tagValueList->nbPairs;
uint8_t nbPairsInPage;
uint8_t i = 0;
bool tooLongToFit;

while (i < tagValueList->nbPairs) {
// upper margin
currentHeight += 24;
nbPairsInPage = nbgl_useCaseGetNbTagValuesInPage(nbPairs, tagValueList, i, &tooLongToFit);
i += nbPairsInPage;
setNbPairs(nbPages, nbPairsInPage, tooLongToFit);
Expand Down

0 comments on commit 681c11d

Please sign in to comment.