1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-03 22:56:33 +02:00

sm: Emit STATUS_FAILURE for non-implemented commands.

* sm/gpgsm.c (main): Do it here.
This commit is contained in:
Werner Koch 2023-05-22 17:00:54 +02:00
parent cd7f286486
commit 5f46bcaaa0
No known key found for this signature in database
GPG key ID: E3FDFF218E45B72B
2 changed files with 13 additions and 5 deletions

View file

@ -1530,7 +1530,7 @@ gpgsm_status_with_err_code (ctrl_t ctrl, int no, const char *text,
{
char buf[30];
sprintf (buf, "%u", (unsigned int)ec);
snprintf (buf, sizeof buf, "%u", (unsigned int)ec);
if (text)
return gpgsm_status2 (ctrl, no, text, buf, NULL);
else