diff options
author | Max Khon <fjoe@FreeBSD.org> | 2017-10-17 18:31:59 +0000 |
---|---|---|
committer | Max Khon <fjoe@FreeBSD.org> | 2017-10-17 18:31:59 +0000 |
commit | 9c14061da66637a3812b2df21c6d6a26b41a9d94 (patch) | |
tree | d9c9bada95a462e8791fb8e9d26a307792e00201 /misc/estic | |
parent | 31c5c62eed3316c515dee940c86a4862f690582b (diff) | |
download | ports-9c14061da66637a3812b2df21c6d6a26b41a9d94.tar.gz ports-9c14061da66637a3812b2df21c6d6a26b41a9d94.zip |
Use fgets(3)+strcspn(3) instead of gets(3)
Approved by: MAINTAINER
Notes
Notes:
svn path=/head/; revision=452288
Diffstat (limited to 'misc/estic')
-rw-r--r-- | misc/estic/Makefile | 2 | ||||
-rw-r--r-- | misc/estic/files/patch-areacode-actest.c | 12 |
2 files changed, 13 insertions, 1 deletions
diff --git a/misc/estic/Makefile b/misc/estic/Makefile index 111c0d9611cd..5a8fc261a190 100644 --- a/misc/estic/Makefile +++ b/misc/estic/Makefile @@ -3,7 +3,7 @@ PORTNAME= estic PORTVERSION= 1.61 -PORTREVISION= 5 +PORTREVISION= 6 CATEGORIES= misc comms MASTER_SITES= LOCAL/dinoex PKGNAMESUFFIX?= ${NOX11_SUFFIX}${PKGNAMESUFFIX2} diff --git a/misc/estic/files/patch-areacode-actest.c b/misc/estic/files/patch-areacode-actest.c new file mode 100644 index 000000000000..940062702c7a --- /dev/null +++ b/misc/estic/files/patch-areacode-actest.c @@ -0,0 +1,12 @@ +--- areacode/actest.c.orig 1997-02-16 11:22:50.000000000 +0000 ++++ areacode/actest.c 2017-10-17 18:26:38.899231000 +0000 +@@ -60,7 +60,8 @@ + + printf ("Enter phone number: "); + fflush (stdout); +- gets (Buf); ++ fgets (Buf, sizeof(Buf), stdin); ++ Buf[strcspn (Buf, "\n")] = '\0'; + if (strlen (Buf) == 0) { + break; + } |