From 330722bb68bacf04cf15be85a46710ffb20c5cbd Mon Sep 17 00:00:00 2001 From: =?utf8?q?=E8=AB=8F=E8=A8=AA=E5=AD=90?= Date: Thu, 1 Feb 2024 16:14:57 +0900 Subject: [PATCH] =?utf8?q?=E3=83=91=E3=82=B9=E3=83=AF=E3=83=BC=E3=83=89?= =?utf8?q?=E3=81=AE=E9=95=B7=E3=81=95=E3=81=AE=E5=BB=B6=E9=95=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- addpass.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/addpass.c b/addpass.c index 2a9a2e7..c30072d 100644 --- a/addpass.c +++ b/addpass.c @@ -74,8 +74,8 @@ void getpasswd(char* prompt, char*pw, size_t pwlen) { } void addpass(char* file) { - char pass[100]; - char knin[100]; + char pass[256]; + char knin[256]; // パスワードを受け取る getpasswd("パスワード: ", pass, sizeof(pass)); @@ -148,8 +148,8 @@ void addpass(char* file) { return; } - char* keyid = malloc(100); - if (!fgets(keyid, 100, keyfile)) { + char* keyid = malloc(256); + if (!fgets(keyid, 256, keyfile)) { perror("鍵IDを読込に失敗。"); fclose(keyfile); free(keyid); -- 2.43.0