left-pad TOTP code with 0s
This commit is contained in:
parent
e99450e2e2
commit
979ec38ec4
@ -189,7 +189,7 @@ executive_totp (void *h_key,
|
|||||||
if (NULL == ret)
|
if (NULL == ret)
|
||||||
{
|
{
|
||||||
GNUNET_asprintf (&ret,
|
GNUNET_asprintf (&ret,
|
||||||
"%llu",
|
"%08llu",
|
||||||
(unsigned long long) code);
|
(unsigned long long) code);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -197,7 +197,7 @@ executive_totp (void *h_key,
|
|||||||
char *tmp;
|
char *tmp;
|
||||||
|
|
||||||
GNUNET_asprintf (&tmp,
|
GNUNET_asprintf (&tmp,
|
||||||
"%s\n%llu",
|
"%s\n%08llu",
|
||||||
ret,
|
ret,
|
||||||
(unsigned long long) code);
|
(unsigned long long) code);
|
||||||
GNUNET_free (ret);
|
GNUNET_free (ret);
|
||||||
|
Loading…
Reference in New Issue
Block a user