Don't access non-existing element buf[256], use buf[255] instead.
Submitted by: draslar <draslar@elray.ch>
This commit is contained in:
parent
1456d1860e
commit
60f7492646
@ -75,7 +75,7 @@ main()
|
||||
buf[0]='\0';
|
||||
fgets(buf,256,stdin);
|
||||
if (buf[0] == '\0') break;
|
||||
buf[256]='\0';
|
||||
buf[255]='\0';
|
||||
i=strlen(buf);
|
||||
p=OPENSSL_malloc(i+1);
|
||||
memcpy(p,buf,i+1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user