From 28624ca43f4ff646e2815ee8f4620788665a3b3e Mon Sep 17 00:00:00 2001 From: Cody Boone Ferguson <53008573+xexyl@users.noreply.github.com> Date: Fri, 7 Apr 2023 10:41:06 -0700 Subject: [PATCH] Undo arg check in 1993/plummer As part of redefining INABIAF the check for args was removed. Instead it's warned about in the Makefile and README.md file. --- 1993/plummer/Makefile | 1 + 1993/plummer/README.md | 5 ++--- 1993/plummer/plummer.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/1993/plummer/Makefile b/1993/plummer/Makefile index d2d7073e1..c7f3f4a75 100644 --- a/1993/plummer/Makefile +++ b/1993/plummer/Makefile @@ -128,6 +128,7 @@ all: data ${TARGET} supernova deep_magic magic charon pluto ${PROG}: ${PROG}.c + @echo "NOTE: this program will crash with not enough args." ${CC} ${CFLAGS} $< -o $@ ${LIBS} # alternative executable diff --git a/1993/plummer/README.md b/1993/plummer/README.md index 9dc3b64fb..3da60d124 100644 --- a/1993/plummer/README.md +++ b/1993/plummer/README.md @@ -18,9 +18,8 @@ where: number is a number (try 21701) arg is any argument -[Cody Boone Ferguson](/winners.html#Cody_Boone_Ferguson) added a check in the -code so that it will not segfault if not enough args are specified. Thank you -Cody! + +NOTE: this entry will crash without enough args. ## Judges' comments: diff --git a/1993/plummer/plummer.c b/1993/plummer/plummer.c index af348c6f8..d0c61daa2 100644 --- a/1993/plummer/plummer.c +++ b/1993/plummer/plummer.c @@ -1 +1 @@ -char*_,*O;main(S,l)char**l;{if(S>2){*(O=*(l+++S-1)-1)=13,*l[1]=0;for(;;)for(printf(*l),_=O-1;_>=*l&&++*_>(S+*O+S)*S;*_--=(S+*O)*S);}} +char*_,*O;main(S,l)char**l;{*(O=*(l+++S-1)-1)=13,*l[1]=0;for(;;)for(printf(*l),_=O-1;_>=*l&&++*_>(S+*O+S)*S;*_--=(S+*O)*S);}