Skip to content

Commit c681b3b

Browse files
committed
sprintf
1 parent bb4832a commit c681b3b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

views/flipbip39_scene_1.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,10 +104,10 @@ static void flipbip39_scene_1_model_init(FlipBip39Scene1Model* const model, cons
104104
// WIP / TODO: Generate a seed from the mnemonic
105105
uint8_t seed[64];
106106
mnemonic_to_seed(mnemonic, "", seed, 0);
107-
char *seedptr = malloc(64*2 + 1);
107+
char *seedptr = malloc(64 * 2 + 1);
108108

109109
for (size_t i = 0; i < 64; i++) {
110-
sprintf(seedptr + (i * 2), "%.2x", seed[i]);
110+
snprintf(seedptr + (i * 2), 2, "%.2x", seed[i]);
111111
}
112112

113113
//strcpy(seedptr, (char*)seed);

0 commit comments

Comments
 (0)