From c8c88eaa96b806e43bff19f672f035c6deab971d Mon Sep 17 00:00:00 2001
From: Cody Boone Ferguson <53008573+xexyl@users.noreply.github.com>
Date: Wed, 20 Mar 2024 06:21:04 -0700
Subject: [PATCH] Fix bug statuses of 2000/dlowe
The doesn't work with some platforms is wrong. It's the perl version and
the author noted this.
There is however a bug that was noted in the bugs file that was not in
the README.md file. This has been moved in the bugs.md file and
README.md file to above the INABIAF part.
---
2000/dlowe/README.md | 2 +-
2000/dlowe/index.html | 4 +-
bugs.html | 337 +++++++++++++++++++++---------------------
bugs.md | 120 ++++++++-------
4 files changed, 229 insertions(+), 234 deletions(-)
diff --git a/2000/dlowe/README.md b/2000/dlowe/README.md
index 94236f204..0b7a3d170 100644
--- a/2000/dlowe/README.md
+++ b/2000/dlowe/README.md
@@ -18,8 +18,8 @@ perl -MConfig -e 'print "$Config{archlibexp}/CORE\n"'
The current status of this entry is:
```
-STATUS: doesn't work with some platforms - please help us fix
STATUS: known bug - please help us fix
+STATUS: INABIAF - please **DO NOT** fix
```
For more detailed information see [2000 dlowe bugs](../../bugs.html#2000_dlowe).
diff --git a/2000/dlowe/index.html b/2000/dlowe/index.html
index 1a4e8a446..1428b8815 100644
--- a/2000/dlowe/index.html
+++ b/2000/dlowe/index.html
@@ -146,8 +146,8 @@ Location: US - United States of America
… just in case the Makefile does not figure this out for you. The current status of this entry is: For more detailed information see 2000 dlowe bugs.Bugs and (Mis)features:
+STATUS: doesn't work with some platforms - please help us fix
-STATUS: known bug - please help us fixSTATUS: known bug - please help us fix
+STATUS: INABIAF - please **DO NOT** fixTo use:
./dlowe [file ...]
There was no IOCCC in 1999.
This MIGHT be better described as doesn’t work with some versions of perl:
-the author states that in perl < 5.6.0 there is a bug with a core dump in what
-they said is in Perl_sv_upgrade. This does not exist in the code, seemingly,
-but it might be that this is impossible to fix without getting a perl upgrade.
-In any event the below details a problem. Another bug that happens in linux also
-is below.
In macOS this program crashes. A tip from Cody is that the code that crashes is:
-perl_eval_sv
-(newSVpv("_:$_= <> ; defined or exit; @ARGV"
-"=split; __:$_= shift;defined or goto _; chomp "
-";(m*^\\x70oO" "\\x74$*i)?(pri" "nt \"$_ w\\x"
-"61s h\\145r\\x" "65!\\n\"):((m*" "^\\s\\*(-?\\d+"
-"(\\.\\d+)?)\\s" "\\*$*)?(push@SS ,$1):(&{chr(((o"
-"rd)%39)+3**4)x2 } )); goto __; sub ff { @SS= ("
-")} sub __{print \"stack empty\\" "n\"} sub ss{$#"
-"SS<0 and goto & __; print $SS[$" "#SS].\"\\n\"} "
-"sub SS{ $#SS<0 and goto &__ ; print pop @SS}"
-"sub _ { print \"divide by zer" "o\\n\"}sub ii{"
-"map{ print\"$_" "\\n\" } reverse @SS} sub AUTOLO"
-"AD { print\"un" "implemented\\n" "\"} sub gg{ $#"
-"SS<0 and goto &__;push@SS,$SS[ $#SS]} sub uu{ "
-"$#SS<1 and goto &__;$SS[ $#SS]+= $SS[$#SS-1];$SS"
-"[$#SS-1]=$SS[$" "#SS]-$SS[$#SS-" "1]; $SS[$#SS]-"
-"=$SS[$#SS-1]} ",0),0 );and in particular it appears that it is the perl itself. In other words if one -changes it to be:
-perl_eval_sv(newSVpv("",0),0);it will not crash. But of course it won’t do anything either. So it’s more
-specifically that the call to newSVpv() crashes the code but INSIDE
-(key point!) the call to perl_eval_sv() that does it. Given what the author
-stated and that the version of perl is < than 5.6.0 that might be exactly what
-is going on.
The example command above should print:
-$ echo "13 14 15 16 17 + - * / p" | ./dlowe
--0.0515873015873016and that’s what it shows in linux.
-Note that with different perl libraries in macOS (for instance from -Homebrew and MacPorts it will -likely print different warnings when compiling. It was observed that with -Homebrew it does not report any warnings but with MacPorts it results in a total -of 92 warnings! Nonetheless neither works okay and both crash.
-The author gives an example command:
-echo "7 P 6 d P P 8 p" | ./dlowe | tr 876 tpoecho "7 P 6 d P P 8 p" | ./dlowe | tr 876 tpowhich should print out poot but it doesn’t, not in linux and not in macOS.
In linux it doesn’t crash but it doesn’t print anything out either.
In macOS it crashes; it might appear to not crash in macOS but this is because
of the pipeline. If you remove the | tr 876 tpo part of the command you will
see that it does indeed crash!
The reason for this not working is really strange.
-$ echo "7 P 6 d P P 8 p" | ./dlowe
-7668
-$ echo "7 P 6 d P P 8 p" | ./dlowe | grep 7
-$$ echo "7 P 6 d P P 8 p" | ./dlowe
+7668
+$ echo "7 P 6 d P P 8 p" | ./dlowe | grep 7
+$Why? Is it writing to stdout? Let’s try some other things:
-$ echo 7668 | tr 876 tpo
-poot$ echo 7668 | tr 876 tpo
+pootOkay so we know that it SHOULD work. But we also know something funny is going on with stdout and the entry. Another experiment:
-$ echo "7 P 6 d P P 8 p" | ./dlowe 1>&2 | grep 7
-7668$ echo "7 P 6 d P P 8 p" | ./dlowe 1>&2 | grep 7
+7668Okay so now it sees it, grep. But watch!
$ echo "7 P 6 d P P 8 p" | ./dlowe 2>foo 1>&1
-7668
-$ cat foo$ echo "7 P 6 d P P 8 p" | ./dlowe 2>foo 1>&1
+7668
+$ cat foo.. so at this hour it does appear to be writing to stdout but yet somehow it doesn’t? But watch:
-$ echo "7 P 6 d P P 8 p" | ./dlowe 1>foo 1>&1
-$ cat foo
-$$ echo "7 P 6 d P P 8 p" | ./dlowe 1>foo 1>&1
+$ cat foo
+$Well this explains why the tr does not transliterate it to poot but why is
this happening? Why can’t it be redirected to another file even?
If it could be figured out why it’s not writing to stdout and yet at the same time is writing to stdout one bug could be fixed. Maybe it’s the perl messing with things but we don’t know.
Other commands do work, however, and give the appropriate output, such as:
-$ echo 1 2 + p | ./dlowe
-3$ echo 1 2 + p | ./dlowe
+3so something is wrong with some commands/operators.
Another feature that does work in linux is:
-$ echo poot | ./dlowe
-poot was here!$ echo poot | ./dlowe
+poot was here!Can you help fix these problems?
Cody provided the C code that creates an unformatted perl script that will just
print ‘unimplemented’ for operators but it seems to work in some other ways (see
@@ -1292,29 +1250,29 @@ below for how to go further than unimplemented) which is the exact perl from the
C program except that it has the #!/usr/bin/env perl and use warnings; as
well. A note below might suggest that doing this creates incomplete perl.
Anyway:
#include <stdio.h>
-int main(void)
-{
- printf("#!/usr/bin/env perl\nuse warnings;_:$_= <> ; defined or exit; @ARGV"
- "=split; __:$_= shift;defined or goto _; chomp "
- ";(m*^\\x70oO" "\\x74$*i)?(pri" "nt \"$_ w\\x"
- "61s h\\145r\\x" "65!\\n\"):((m*" "^\\s\\*(-?\\d+"
- "(\\.\\d+)?)\\s" "\\*$*)?(push@SS ,$1):(&{chr(((o"
- "rd)%%39)+3**4)x2 } )); goto __; sub ff { @SS= ("
- ")} sub __{print \"stack empty\\" "n\"} sub ss{$#"
- "SS<0 and goto & __; print $SS[$" "#SS].\"\\n\"} "
- "sub SS{ $#SS<0 and goto &__ ; print pop @SS}"
- "sub _ { print \"divide by zer" "o\\n\"}sub ii{"
- "map{ print\"$_" "\\n\" } reverse @SS} sub AUTOLO"
- "AD { print\"un" "implemented\\n" "\"} sub gg{ $#"
- "SS<0 and goto &__;push@SS,$SS[ $#SS]} sub uu{ "
- "$#SS<1 and goto &__;$SS[ $#SS]+= $SS[$#SS-1];$SS"
- "[$#SS-1]=$SS[$" "#SS]-$SS[$#SS-" "1]; $SS[$#SS]-"
- "=$SS[$#SS-1]}");
-}#include <stdio.h>
+int main(void)
+{
+ printf("#!/usr/bin/env perl\nuse warnings;_:$_= <> ; defined or exit; @ARGV"
+ "=split; __:$_= shift;defined or goto _; chomp "
+ ";(m*^\\x70oO" "\\x74$*i)?(pri" "nt \"$_ w\\x"
+ "61s h\\145r\\x" "65!\\n\"):((m*" "^\\s\\*(-?\\d+"
+ "(\\.\\d+)?)\\s" "\\*$*)?(push@SS ,$1):(&{chr(((o"
+ "rd)%%39)+3**4)x2 } )); goto __; sub ff { @SS= ("
+ ")} sub __{print \"stack empty\\" "n\"} sub ss{$#"
+ "SS<0 and goto & __; print $SS[$" "#SS].\"\\n\"} "
+ "sub SS{ $#SS<0 and goto &__ ; print pop @SS}"
+ "sub _ { print \"divide by zer" "o\\n\"}sub ii{"
+ "map{ print\"$_" "\\n\" } reverse @SS} sub AUTOLO"
+ "AD { print\"un" "implemented\\n" "\"} sub gg{ $#"
+ "SS<0 and goto &__;push@SS,$SS[ $#SS]} sub uu{ "
+ "$#SS<1 and goto &__;$SS[ $#SS]+= $SS[$#SS-1];$SS"
+ "[$#SS-1]=$SS[$" "#SS]-$SS[$#SS-" "1]; $SS[$#SS]-"
+ "=$SS[$#SS-1]}");
+}Compiling this you can generate:
-#!/usr/bin/env perl
-use warnings;_:$_= <> ; defined or exit; @ARGV=split; __:$_= shift;defined or goto _; chomp ;(m*^\x70oO\x74$*i)?(print "$_ w\x61s h\145r\x65!\n"):((m*^\s\*(-?\d+(\.\d+)?)\s\*$*)?(push@SS ,$1):(&{chr(((ord)%39)+3**4)x2 } )); goto __; sub ff { @SS= ()} sub __{print "stack empty\n"} sub ss{$#SS<0 and goto & __; print $SS[$#SS]."\n"} sub SS{ $#SS<0 and goto &__ ; print pop @SS}sub _ { print "divide by zero\n"}sub ii{map{ print"$_\n" } reverse @SS} sub AUTOLOAD { print"unimplemented\n"} sub gg{ $#SS<0 and goto &__;push@SS,$SS[ $#SS]} sub uu{ $#SS<1 and goto &__;$SS[ $#SS]+= $SS[$#SS-1];$SS[$#SS-1]=$SS[$#SS]-$SS[$#SS-1]; $SS[$#SS]-=$SS[$#SS-1]}#!/usr/bin/env perl
+use warnings;_:$_= <> ; defined or exit; @ARGV=split; __:$_= shift;defined or goto _; chomp ;(m*^\x70oO\x74$*i)?(print "$_ w\x61s h\145r\x65!\n"):((m*^\s\*(-?\d+(\.\d+)?)\s\*$*)?(push@SS ,$1):(&{chr(((ord)%39)+3**4)x2 } )); goto __; sub ff { @SS= ()} sub __{print "stack empty\n"} sub ss{$#SS<0 and goto & __; print $SS[$#SS]."\n"} sub SS{ $#SS<0 and goto &__ ; print pop @SS}sub _ { print "divide by zero\n"}sub ii{map{ print"$_\n" } reverse @SS} sub AUTOLOAD { print"unimplemented\n"} sub gg{ $#SS<0 and goto &__;push@SS,$SS[ $#SS]} sub uu{ $#SS<1 and goto &__;$SS[ $#SS]+= $SS[$#SS-1];$SS[$#SS-1]=$SS[$#SS]-$SS[$#SS-1]; $SS[$#SS]-=$SS[$#SS-1]}Here is example input/output:
p
stack empty
@@ -1331,32 +1289,32 @@ p
how this does not happen in the C program in linux!) but if one uses ‘p’ by
itself it will print what’s on the stack (for example).
To not get ‘unimplemented’ you can remove from the perl:
-sub AUTOLOAD { print"unimplemented\n"}
+sub AUTOLOAD { print"unimplemented\n"}
(Note that the author stated this was used for exception handling so another
possibility is that the C code doesn’t generate the correct perl and indeed even
spaces is known to break the perl in at least one way, syntax errors, but maybe
others too.)
Here is an example run of several operations in the perl script after removing
that subroutine:
-$ echo 5 5 p | ./dlowe.pl
-5
-$ echo 5 5 + p | ./dlowe.pl
-5
-Undefined subroutine &main::UU called at ./pl.pl line 2, <> line 1.
-$ echo 5 5 * p | ./dlowe.pl
-5
-Undefined subroutine &main::ww called at ./pl.pl line 2, <> line 1.
-$ echo 5 5 - p | ./dlowe.pl
-5
-Undefined subroutine &main::WW called at ./pl.pl line 2, <> line 1.
-$ echo 5 5 / p | ./dlowe.pl
-5
-Undefined subroutine &main::YY called at ./pl.pl line 2, <> line 1.
-$ echo 5 P | ./dlowe.pl
-5$ echo p | ./dlowe.pl
-stack empty
-$ echo P | ./dlowe.pl
-stack empty
+$ echo 5 5 p | ./dlowe.pl
+5
+$ echo 5 5 + p | ./dlowe.pl
+5
+Undefined subroutine &main::UU called at ./pl.pl line 2, <> line 1.
+$ echo 5 5 * p | ./dlowe.pl
+5
+Undefined subroutine &main::ww called at ./pl.pl line 2, <> line 1.
+$ echo 5 5 - p | ./dlowe.pl
+5
+Undefined subroutine &main::WW called at ./pl.pl line 2, <> line 1.
+$ echo 5 5 / p | ./dlowe.pl
+5
+Undefined subroutine &main::YY called at ./pl.pl line 2, <> line 1.
+$ echo 5 P | ./dlowe.pl
+5$ echo p | ./dlowe.pl
+stack empty
+$ echo P | ./dlowe.pl
+stack empty
Note the undefined subroutine error: that happens with commands that are not
even in the program. Again the author used AUTOLOAD for exception handling so
it seems likely that there is something missing (which the below shows as well).
@@ -1369,13 +1327,52 @@ works in the code, at least in some cases.
invalid input. But as can be seen by the input I (Cody) gave the input is not
actually incorrect. It is also curious to note that it ends up printing what’s
on the stack at that point:
-$ echo 5 5 + p | ./dlowe.pl
-unimplemented
-5
+$ echo 5 5 + p | ./dlowe.pl
+unimplemented
+5
which might (?) suggest that the + operator is unimplemented. Unfortunately it
has been many years since I have used perl and I was never a guru either.
-2000/primenum
STATUS: INABIAF - please DO NOT fix
+The author states that in perl < 5.6.0 there is a bug with a core dump in what
+they said is in Perl_sv_upgrade. As this is documented it is not considered a
+bug to be fixed. For the curious this will crash in macOS. Cody notes that the
+code that crashes is:
+perl_eval_sv
+(newSVpv("_:$_= <> ; defined or exit; @ARGV"
+"=split; __:$_= shift;defined or goto _; chomp "
+";(m*^\\x70oO" "\\x74$*i)?(pri" "nt \"$_ w\\x"
+"61s h\\145r\\x" "65!\\n\"):((m*" "^\\s\\*(-?\\d+"
+"(\\.\\d+)?)\\s" "\\*$*)?(push@SS ,$1):(&{chr(((o"
+"rd)%39)+3**4)x2 } )); goto __; sub ff { @SS= ("
+")} sub __{print \"stack empty\\" "n\"} sub ss{$#"
+"SS<0 and goto & __; print $SS[$" "#SS].\"\\n\"} "
+"sub SS{ $#SS<0 and goto &__ ; print pop @SS}"
+"sub _ { print \"divide by zer" "o\\n\"}sub ii{"
+"map{ print\"$_" "\\n\" } reverse @SS} sub AUTOLO"
+"AD { print\"un" "implemented\\n" "\"} sub gg{ $#"
+"SS<0 and goto &__;push@SS,$SS[ $#SS]} sub uu{ "
+"$#SS<1 and goto &__;$SS[ $#SS]+= $SS[$#SS-1];$SS"
+"[$#SS-1]=$SS[$" "#SS]-$SS[$#SS-" "1]; $SS[$#SS]-"
+"=$SS[$#SS-1]} ",0),0 );
+and in particular it appears that it is the perl itself. In other words if one
+changes it to be:
+perl_eval_sv(newSVpv("",0),0);
+it will not crash. But of course it won’t do anything either. So it’s more
+specifically that the call to newSVpv() crashes the code but INSIDE
+(key point!) the call to perl_eval_sv() that does it. Given what the author
+stated and that the version of perl is < than 5.6.0 which the author states can
+crash this makes sense.
+The example command above should print:
+$ echo "13 14 15 16 17 + - * / p" | ./dlowe
+-0.0515873015873016
+and that’s what it shows in linux.
+Note that with different perl libraries in macOS (for instance from
+Homebrew and MacPorts it will
+likely print different warnings when compiling. It was observed that with
+Homebrew it does not report any warnings but with MacPorts it results in a total
+of 92 warnings! Nonetheless neither works okay and both crash.
+2000/primenum
+STATUS: INABIAF - please DO NOT fix
Source code: 2000/primenum/primenum.c
Information: 2000/primenum/index.html
This program does not do what you might think it does! Running it like:
@@ -1391,7 +1388,7 @@ try to fix the crashing of this code except to challenge yourself (if you think
that it’ll be worth your two second fix :-) ). If you do fix it please do not
make a pull request.
2000/rince
-STATUS: INABIAF - please DO NOT fix
+STATUS: INABIAF - please DO NOT fix
Source code: 2000/rince/rince.c
Information: 2000/rince/index.html
If DISPLAY is not set the program will very likely crash, do something strange
@@ -1399,7 +1396,7 @@ make a pull request.
fire! :-) ).
2001
2001/anonymous
-STATUS: INABIAF - please DO NOT fix
+STATUS: INABIAF - please DO NOT fix
Source code: 2001/anonymous/anonymous.c
Information: 2001/anonymous/index.html
Cody Boone Ferguson fixed this so that it
@@ -1420,8 +1417,8 @@ can run ELF binaries but cannot compile 32-bit binaries.
this program will very likely crash or do something strange like slaughter the
elves of Imladris :-(
2001/bellard
-STATUS: INABIAF - please DO NOT fix
-STATUS: doesn’t work with some platforms - please help us fix
+STATUS: INABIAF - please DO NOT fix
+STATUS: doesn’t work with some platforms - please help us fix
Source code: 2001/bellard/bellard.c
Information: 2001/bellard/index.html
The two statuses might seem contradictory but that is a complicated question.
@@ -1469,7 +1466,7 @@ the compiler won’t work there.
and it can be run by itself for fun in modern systems, which was not possible
before the fixes there.
2001/dgbeards
-STATUS: INABIAF - please DO NOT fix
+STATUS: INABIAF - please DO NOT fix
Source code: 2001/dgbeards/dgbeards.c
Information: 2001/dgbeards/index.html
This program deliberately crashes if it loses (which is what it aims to do).
@@ -1486,7 +1483,7 @@ that version 2.95 works but maybe others do as well. Do you have a fix? We would
appreciate your help!
If you want to try and fix this (mis)feature, you are welcome to try.
2001/kev
-STATUS: INABIAF - please DO NOT fix
+STATUS: INABIAF - please DO NOT fix
Source code: 2001/kev/kev.c
Information: 2001/kev/index.html
Sometimes when one player presses q it will result in broken pipe on the other
@@ -1508,7 +1505,7 @@ set. In other words both have to be ASCII or EBCDIC - not one of each.
The author stated that there is a cat man page for this program in case one
wanted to install it as a tool but this is missing.
2001/schweikh
-STATUS: INABIAF - please DO NOT fix
+STATUS: INABIAF - please DO NOT fix
Source code: 2001/schweikh/schweikh.c
Information: 2001/schweikh/index.html
The glob pattern must match the whole string. See the author’s comments for
@@ -1576,7 +1573,7 @@ sleeping.
2004
2004/gavin
STATUS: compiled executable crashes - please help us fix
-STATUS: doesn’t work with some platforms - please help us fix
+STATUS: doesn’t work with some platforms - please help us fix
Source code: 2004/gavin/gavin.c
Information: 2004/gavin//index.html
Segmentation fault will occur in some systems. For instance on macOS with the
@@ -1658,11 +1655,11 @@ gavin_clobber: gavin_clean
gavin_files: boot.b lilo.conf prim gavin_install.txt
The current (Makefile was modified to try and fit into the current IOCCC build environment.
-See known features in the index.html for things that are not bugs but documented (mis)features.
The author stated that:
@@ -1685,14 +1682,14 @@ incorrect results (e.g., generation 1 starting from a string of 257 `1`s will be calculated as `11`); the remark from the previous paragraph applies here also.The generated code will very likely segfault or do something not intended if not given the right args. See the index.html file for the correct syntax.
This program sometimes will create unsolvable puzzles :-) just to hook you. @@ -1704,14 +1701,14 @@ details on this.
strange. This might also happen if you specify excessively large board dimensions. Try100 100 100 for instance and see what happens!
This entry will very likely segfault or do something strange if the source code does not exist.
This entry requires that sed and make are in the path.
The author states:
@@ -1743,7 +1740,7 @@ nowhere nearBasically, the [LISP][] interpreter is good for some basic math operations, and for running itself.
Cody Boone Ferguson notes that, though @@ -1755,7 +1752,7 @@ set up in order to give http commands. This is not a bug but it’s worth pointi out as it won’t work on as many websites as it used to including the IOCCC website itself.
The author stated the below points of interest.
@@ -1788,14 +1785,14 @@ with at leastcomputer.tofu input file:
12a13
#define gets(c) fgets((c),PI,stdin)&&(((c)[strlen((c))-1]='\0'),c!=NULL)The string specified must be <= 42 characters and may only consist of the
characters in the regex a-z_A-Z0-9@.-. Breaking these constraints will end up
with possibly corrupt GIF files.
This program requires x86 (with an x87 FPU) or x86_64 machine and it requires @@ -1807,10 +1804,10 @@ but you are welcome to try and fix it.
provide it as an additional alt version. Fixing this is very likely to be very challenging and in some systems it will not be possible to fix but you are welcome to try and fix it if you wish to! -Incorrect formulas will ungracefully crash the program.
The author stated:
@@ -1825,7 +1822,7 @@ unique solutions. If you pick a number higher than 460464 (24x19186) the program will return without outputting a solution. If you can wait that long.Cody Boone Ferguson fixed this program to @@ -1850,7 +1847,7 @@ case-sensitive.
There was no IOCCC in 2010.
For a great amount of data points the program will crash, depending on your @@ -1871,7 +1868,7 @@ bins at the edges.
instead being something else entirely. The Internet Wayback Machine, although it archived it, did not load scripts. Do you know if the domain was moved? Do you have an archive or mirror? Please provide us it! Thank you. -The author states the following:
Bad input (e.g. nonexistent files, non-numeric number of iterations, etc.) @@ -1882,7 +1879,7 @@ tends to result in empty output.
If you want to try and fix this (mis)feature, you are welcome to try.
The author stated that there are a number of features and limitations. As the @@ -1890,7 +1887,7 @@ list is rather long see oth features and limitations and remarks instead.
This does not appear to work with macOS, resulting in a segfault (and sometimes
@@ -2051,7 +2048,7 @@ unconfirmed and it’s not known when CONFIG_DYNAMIC_CODE_SIGNING w
defined.
Do you have a fix? We welcome it!
The author stated that the program will crash if no argument is passed to the @@ -2059,14 +2056,14 @@ program though we note that your computer might also 2012
The author stated:
If there is a division by zero, square-root of a negative number, or similar
operation, then the results are undefined.
The author stated:
@@ -2097,7 +2094,7 @@ Therefore, when preparing music in a file, care should be taken that the last musical element of a line is only 2 characters!The manual referred to is here.
The author stated:
@@ -2109,7 +2106,7 @@ doesn’t make it possible to lock drawing to the display refresh rate.)The author stated:
@@ -2129,7 +2126,7 @@ looking into a null-pointer environment: will likely dump core.The author stated that the program will crash if no argument is passed to the @@ -2139,7 +2136,7 @@ might also 2013
The author stated:
@@ -2157,7 +2154,7 @@ antialiasing interferes with color detection in “color” mode. and endianness conversion would make the source too large for IOCCC rule 2).This program will possibly crash or draw something strange with 0 args. Then @@ -2174,7 +2171,7 @@ something funny (or will it? :-) ) and when will it just do nothing?
used.From the author:
@@ -2188,7 +2185,7 @@ used. section.–
From the author:
@@ -2199,18 +2196,18 @@ such asC2E2.
A workaround is inserting a whitespace: C2 E2.
–
Invalid input files will very likely crash the program.
This program will not terminate on its own; you must kill hou (but not Qiming
Hou :-) ) yourself. This should not be fixed.
The author reminds us that if you kill the program you will have to wait a short @@ -2221,7 +2218,7 @@ have experience with socket programming :-) ) fix. However as the author pointed it out as a known limitation it is not a bug but a feature.
The author noted that in macOS the colours might be wrong. They gave a solution. @@ -2243,7 +2240,7 @@ player become bigger, stay away from blocks!
–
but since it’s documented it’s considered a feature, not a bug to fix.
This program will very likely crash if no arg is given.
@@ -2276,7 +2273,7 @@ rely on the entry as the below shows. One should be able to do:IOCCC
The author stated:
@@ -2299,14 +2296,14 @@ result. Error messages become garbled, though.–
The program doesn’t look at the header of files so if it’s passed something hat is not compressed data it’s likely to crash.
The program depends on little endian systems.
The program assumes that There was no IOCCC in 2017. The author wrote: When you run it on a JSON file you will see something like:EOF is -1. This can be fixed but at this time it is
@@ -2325,7 +2322,7 @@ use 8 * sizeof(typ) bits per place. It does not work when CHA
2018
2018/algmyr
-STATUS: INABIAF - please DO NOT fix
+STATUS: INABIAF - please DO NOT fix
Source code: 2018/algmyr/algmyr.c
Information: 2018/algmyr/index.html
2018/hou
-STATUS: INABIAF - please DO NOT fix
+STATUS: INABIAF - please DO NOT fix
Source code: 2018/hou/prog.c
Information: 2018/hou/index.html
where [] is the cursor. When this happens if you hit enter (this is necessary
or else it’ll happen again) and then exit again (ctrl-e) and run prog again
it’ll be okay.
The author stated that if you make a typo it can happen that the boot loader can crash and halt. If this is the case type ctrl-e to quit the emulator and try again.
@@ -2378,7 +2375,7 @@ referred to by the author but there was likely no typo involved. exiting the program or else the next time you run it the file will not exist (or in the case of compiled code it won’t be executable).The author wrote the following:
@@ -2422,19 +2419,19 @@ this program has nothing to do with a hand.Certain input can crash this program. The file crash.unl is an example file.
The author pointed out that some implementations of wc(1) show different
values but his implementation matches that of macOS and FreeBSD.
Cody Boone Ferguson fixed the scripts so @@ -2462,7 +2459,7 @@ in the de.sh/de.alt.sh scripts:
The author does not it uses gets() and one will get warnings but it would be
ideal if this was not the case.
There are two things to be aware of with this entry.
@@ -2489,13 +2486,13 @@ in the directory:find . -exec file '{}' \;|grep socket|cut -f 1 -d: | xargs rm -fthough one might want to check that the program is not currently running. :-)
As a backtrace quine this entry is SUPPOSED to segfault so this should not be touched either.
The author stated the following:
@@ -2517,7 +2514,7 @@ not encountered this myself).The author wrote that there are a number of differences from what one might @@ -2525,7 +2522,7 @@ expect. Rather than duplicate the information we refer you to the author’s remarks in the sections Syntax and Caveats.
The author wrote that if you decide to change networks or use a different input
@@ -2545,14 +2542,14 @@ the hard limit with limit -h stacksize and set it with
limit stacksize 65532 (replacing 65532 with the actual hard limit).
This program will not validate input so it might fail or get stuck if invoked erroneously.
Also, the maximum file size is 1GB.
The author noted that if the program runs out of memory it is likely to crash.
@@ -2561,7 +2558,7 @@ thoseCRs are silently dropped. In fact, most control codes are sil
ignored except line feeds (preserved) and tabs (expanded to 8 spaces).’
This entry is known to crash if no arg is specified. Although easy to fix it is @@ -2570,7 +2567,7 @@ but it shouldn’t be made into a pull request).
It will also show funny output with more than one arg. This should not be fixed either. But can you figure out why this happens?
The author stated that bad things happen if the entered move is outside of the @@ -2582,7 +2579,7 @@ lose.
move.If you have audible bells enabled the program will beep at every turn.
There are some things that might appear to be bugs but are actually features or @@ -2590,14 +2587,14 @@ things that are misinterpreted as bugs. See the bugs.html and troubleshooting.html files for details.
The author noted that the program only supports WAV files that have exactly 16 bits per sample, but it allows any sample rate and any number of audio channels.
The author listed the following limitations:
diff --git a/bugs.md b/bugs.md index b10ea6028..81cd8437a 100644 --- a/bugs.md +++ b/bugs.md @@ -1645,69 +1645,10 @@ There was no IOCCC in 1999. ## 2000/dlowe -### STATUS: doesn't work with some platforms - please help us fix -### Source code: [2000/dlowe/dlowe.c](2000/dlowe/dlowe.c) -### Information: [2000/dlowe/index.html](2000/dlowe/index.html) - -This **MIGHT** be better described as doesn't work with some versions of perl: -the author states that in perl < 5.6.0 there is a bug with a core dump in what -they said is in `Perl_sv_upgrade`. This does not exist in the code, seemingly, -but it might be that this is impossible to fix without getting a perl upgrade. -In any event the below details a problem. Another bug that happens in linux also -is below. - -In macOS this program crashes. A tip from Cody is that the code that crashes is: - -```c -perl_eval_sv -(newSVpv("_:$_= <> ; defined or exit; @ARGV" -"=split; __:$_= shift;defined or goto _; chomp " -";(m*^\\x70oO" "\\x74$*i)?(pri" "nt \"$_ w\\x" -"61s h\\145r\\x" "65!\\n\"):((m*" "^\\s\\*(-?\\d+" -"(\\.\\d+)?)\\s" "\\*$*)?(push@SS ,$1):(&{chr(((o" -"rd)%39)+3**4)x2 } )); goto __; sub ff { @SS= (" -")} sub __{print \"stack empty\\" "n\"} sub ss{$#" -"SS<0 and goto & __; print $SS[$" "#SS].\"\\n\"} " -"sub SS{ $#SS<0 and goto &__ ; print pop @SS}" -"sub _ { print \"divide by zer" "o\\n\"}sub ii{" -"map{ print\"$_" "\\n\" } reverse @SS} sub AUTOLO" -"AD { print\"un" "implemented\\n" "\"} sub gg{ $#" -"SS<0 and goto &__;push@SS,$SS[ $#SS]} sub uu{ " -"$#SS<1 and goto &__;$SS[ $#SS]+= $SS[$#SS-1];$SS" -"[$#SS-1]=$SS[$" "#SS]-$SS[$#SS-" "1]; $SS[$#SS]-" -"=$SS[$#SS-1]} ",0),0 ); -``` - -and in particular it appears that it is the perl itself. In other words if one -changes it to be: - -```c -perl_eval_sv(newSVpv("",0),0); -``` - -it will not crash. But of course it won't do anything either. So it's more -specifically that the call to `newSVpv()` crashes the code but _INSIDE_ -(key point!) the call to `perl_eval_sv()` that does it. Given what the author -stated and that the version of perl is < than 5.6.0 that might be exactly what -is going on. - -The example command above _should_ print: - -```sh -$ echo "13 14 15 16 17 + - * / p" | ./dlowe --0.0515873015873016 -``` - -and that's what it shows in linux. - -Note that with different perl libraries in macOS (for instance from -[Homebrew](https://brew.sh) and [MacPorts](https://www.macports.org) it will -likely print different warnings when compiling. It was observed that with -Homebrew it does not report any warnings but with MacPorts it results in a total -of 92 warnings! Nonetheless neither works okay and both crash. - ### STATUS: known bug - please help us fix +### Source code: [2000/dlowe/dlowe.c](2000/dlowe/dlowe.c) +### Information: [2000/dlowe/index.html](2000/dlowe/index.html) The author gives an example command: @@ -1912,6 +1853,63 @@ which might (?) suggest that the `+` operator is unimplemented. Unfortunately it has been many years since I have used perl and I was never a guru either. +### STATUS: INABIAF - please **DO NOT** fix + +The author states that in perl < 5.6.0 there is a bug with a core dump in what +they said is in `Perl_sv_upgrade`. As this is documented it is not considered a +bug to be fixed. For the curious this will crash in macOS. Cody notes that the +code that crashes is: + +```c +perl_eval_sv +(newSVpv("_:$_= <> ; defined or exit; @ARGV" +"=split; __:$_= shift;defined or goto _; chomp " +";(m*^\\x70oO" "\\x74$*i)?(pri" "nt \"$_ w\\x" +"61s h\\145r\\x" "65!\\n\"):((m*" "^\\s\\*(-?\\d+" +"(\\.\\d+)?)\\s" "\\*$*)?(push@SS ,$1):(&{chr(((o" +"rd)%39)+3**4)x2 } )); goto __; sub ff { @SS= (" +")} sub __{print \"stack empty\\" "n\"} sub ss{$#" +"SS<0 and goto & __; print $SS[$" "#SS].\"\\n\"} " +"sub SS{ $#SS<0 and goto &__ ; print pop @SS}" +"sub _ { print \"divide by zer" "o\\n\"}sub ii{" +"map{ print\"$_" "\\n\" } reverse @SS} sub AUTOLO" +"AD { print\"un" "implemented\\n" "\"} sub gg{ $#" +"SS<0 and goto &__;push@SS,$SS[ $#SS]} sub uu{ " +"$#SS<1 and goto &__;$SS[ $#SS]+= $SS[$#SS-1];$SS" +"[$#SS-1]=$SS[$" "#SS]-$SS[$#SS-" "1]; $SS[$#SS]-" +"=$SS[$#SS-1]} ",0),0 ); +``` + +and in particular it appears that it is the perl itself. In other words if one +changes it to be: + +```c +perl_eval_sv(newSVpv("",0),0); +``` + +it will not crash. But of course it won't do anything either. So it's more +specifically that the call to `newSVpv()` crashes the code but _INSIDE_ +(key point!) the call to `perl_eval_sv()` that does it. Given what the author +stated and that the version of perl is < than 5.6.0 which the author states can +crash this makes sense. + +The example command above _should_ print: + +```sh +$ echo "13 14 15 16 17 + - * / p" | ./dlowe +-0.0515873015873016 +``` + +and that's what it shows in linux. + +Note that with different perl libraries in macOS (for instance from +[Homebrew](https://brew.sh) and [MacPorts](https://www.macports.org) it will +likely print different warnings when compiling. It was observed that with +Homebrew it does not report any warnings but with MacPorts it results in a total +of 92 warnings! Nonetheless neither works okay and both crash. + + + ## 2000/primenum ### STATUS: INABIAF - please **DO NOT** fix