Fix 2005/giljade/giljade.alt.c
In order to not require being compiled as 32-bit the 'long*E' has to be a 'int*E'. This version works fine and I wonder if it should be the main version with alt being for clang that does not work fully: not sure. Updated bugs.md with more information (what I came up with yesterday and today). As a new issue was opened in the mkiocccentry repo I will be doing less here for a while most likely but there probably will still be some commits. I felt however that this was a needed commit to make as it was left unfinished yesterday. I actually can provide a bit more information on this entry but for now it'll suffice. The additional information has to do with what system() is passed.
This commit is contained in:
1 parent
5881f728f5
commit
c5230a9a66
3 files changed
+86
-25
No files matched your search
+14
-11
@@ -16,27 +16,30 @@ make
|
||||
./giljade
|
||||
```
|
||||
|
||||
[Cody Boone Ferguson](/winners.html#Cody_Boone_Ferguson) fixed this for modern
|
||||
systems. The problem that was showing up is that with either optimising or
|
||||
anything but 32-bit was used it would not work. The optimising cannot be used
|
||||
still but it now works with both 32-bit and 64-bit. The problem was the size of
|
||||
`int` and `long` being different now. Instead of `long *E` it is now `int *E`.
|
||||
This solves the problem for both 32-bit and 64-bit as long as optimising is
|
||||
disabled. Tested under linux (32-bit, 64-bit) and macOS (arm64). Thank you Cody
|
||||
for your assistance!
|
||||
[Cody Boone Ferguson](/winners.html#Cody_Boone_Ferguson) partly (see below)
|
||||
fixed this for modern systems. The problem that was showing up is that with
|
||||
either optimising or anything but 32-bit was used it would not work. The
|
||||
optimising cannot be used still but it now works with both 32-bit and 64-bit.
|
||||
The problem was the size of `int` and `long` being different now. Instead of
|
||||
`long *E` it is now `int *E`. This solves the problem for both 32-bit and
|
||||
64-bit as long as optimising is disabled. Tested under linux (32-bit, 64-bit)
|
||||
and macOS (arm64). Thank you Cody for your assistance!
|
||||
|
||||
NOTE: the self-test feature no longer works due to the fix for clang (which
|
||||
requires the first arg of `main()` to be an `int` and the second arg to be `char
|
||||
**`). Believe it having more than two spaces in the code, except where the
|
||||
original code has them, appears to be part of the problem but it's not the full
|
||||
story. If you have a compiler that doesn't have this deficiency (e.g. gcc) you
|
||||
can use the alternate code described below.
|
||||
original code has them, might be part of the problem but it's not the full
|
||||
story. If you have a compiler that doesn't have this defect (e.g. gcc) you
|
||||
can use the alternate code described below. See also [bugs.md](/bugs.md).
|
||||
|
||||
|
||||
### INABIAF - it's not a bug it's a feature! :-)
|
||||
|
||||
If the program source file is not lying in the same directory this program will
|
||||
very likely crash or do something strange.
|
||||
|
||||
This entry requires that both `sed` and `cc` are in the path.
|
||||
|
||||
## Try:
|
||||
|
||||
```sh
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
),l)u=u>>5-m &u;s=u&E[3-l];I(t(m),3-l) s=(u)a&*E;I\
|
||||
(t(m),(0));; /*echo/Line/%d;sed/-n/-e/ %d,%dp/%s>*/
|
||||
/*c.c;cc/c.c /-c*/;;char*A=0,*_,*R,*Q, D[9999],*r,l
|
||||
[9999],T=42, M,V=32;long*E,k[9999],B[1 <<+21],*N=B+
|
||||
[9999],T=42, M,V=32;int*E,k[9999],B[1 <<+21],*N=B+
|
||||
1234567,q=0, h=3,j=2,O,b,f,u,s,c,a,t,e ,d;C(){F(h=N
|
||||
[3];(B[h]&&+ memcmp(N,B+B[h],16));h=B[ h]+4);B[h]||
|
||||
(B[h]=N-B,N= N+6);}main(char*U,int*w[] ){;;F(_=A=D+
|
||||
|
||||
Reference in new issue
Block a user