Was it you?
The fact that I can't remember who I gave it to is driving me crazy, because I used to have a good memory. Oh, time's remorseless arrow!
(Incidentally, anyone have a copy of "Jesus Egg That Wept"?)
Was it you?
The fact that I can't remember who I gave it to is driving me crazy, because I used to have a good memory. Oh, time's remorseless arrow!
(Incidentally, anyone have a copy of "Jesus Egg That Wept"?)
ScreenSaverView.m: init() calls yarandom.c: ya_rand_init(). Then it calls dangerball.c: screenhack(), which later calls yarandom.c: ya_random(). ScreenSaverView.m is ObjC, everything else is C.
So I've sprinkled some test code around. It looks like this: In yarandom.c I've got:
Every call to TEST() made from ScreenSaverView.m after calling ya_rand_init() succeeds. In particular: it calls TEST() then immediately calls screenhack(). The very first line in screenhack() is a call to TEST() which fails, because bad_craziness is 0xABCD1234 instead of 0xDEADBEEF. The value appears to change back to its previous value halfway through setting up the stack frame.
So maybe what's going on is not that it's getting reset, but that somehow there are two copies of the yarandom.o code loaded, and different ones are being seen by the two files? (Update: yes.) But they were all loaded together from the same .saver bundle.
W, I must ask, TF?