Make 1990/tbr alt version that uses fgets not gets

This is so that the warning about gets() is not interspersed with the
initial output of the program (see below). I do want to note that if one
sends EOF it will segfault so to exit one should do ctrl-c (for
instance) (exit never worked). I will look at fixing that fault later on
to match the original code but this is good for now. When fixed (low
priority though) I will consider making the gets() version the alt but
probably not (I guess time will tell).

As for the interspersed output it looks like:

    $ warning: this program uses gets(), which is unsafe.
    # cursor is here

At the cursor I can either hit enter to get another prompt or I can
input a command but this is not immediately obvious.

Updated .gitignore to have tbr.alt.
This commit is contained in:
Cody Boone Ferguson committed 2023-03-21 05:58:50 -07:00
1 parent e6d578660b
commit 6a6807e587
4 files changed
+45 -4

No files matched your search

+1
View File
@@ -1 +1,2 @@
tbr
tbr.alt