summaryrefslogtreecommitdiff
path: root/misc/estic/files/patch-areacode-actest.c
diff options
context:
space:
mode:
Diffstat (limited to 'misc/estic/files/patch-areacode-actest.c')
-rw-r--r--misc/estic/files/patch-areacode-actest.c12
1 files changed, 12 insertions, 0 deletions
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;
+ }