Screen corruption & possible crash (*solved*) - Printable Version +- Forum (https://www.boriel.com/forum) +-- Forum: Compilers and Computer Languages (https://www.boriel.com/forum/forumdisplay.php?fid=12) +--- Forum: ZX Basic Compiler (https://www.boriel.com/forum/forumdisplay.php?fid=11) +---- Forum: Bug Reports (https://www.boriel.com/forum/forumdisplay.php?fid=15) +---- Thread: Screen corruption & possible crash (*solved*) (/showthread.php?tid=279) |
Screen corruption & possible crash (*solved*) - LCD - 08-15-2010 I wrote a function to transform Speccy frames to a timer: Code: function Clock(tim as uinteger) as String Reducing the Heap size from default to 100 caused no corrupted screen memory, but a complete crash. Oh, and I'm using the latest devel version. Edit: It looks like there is a leak in the STR function, as without STR my program does not crash after a while. Re: Screen corruption & possible crash - britlion - 08-16-2010 I have a program that uses strings as input and output to functions (without being able to make data types, strings are easiest). This program breaks badly, and I haven't been able to track where - the spectrum just resets; even with the debugging code in. I'm wondering if I'm hitting a similar problem. Hmm. Re: Screen corruption & possible crash - boriel - 08-16-2010 This could be a nasty hard memory-corruption bug. I will check it deeply :? and tell you the results. Re: Screen corruption & possible crash - boriel - 08-19-2010 LCD, I have discovered that, removing line Code: s$ = "" Meanwhile, can you check your program removing this line? Re: Screen corruption & possible crash - LCD - 08-20-2010 boriel Wrote:LCD, I have discovered that, removing line I added this line only for testing. It still happen, but after a longer time, even longer if I remove DIM s$ as String. This is the actual version of Clock Function: Code: function Clock(tim as uinteger) as String Sorry it it is not that easy. Re: Screen corruption & possible crash - boriel - 11-12-2010 Ok, back into this UltraNasty bug. It seems to be related to the STR$() function (which is already buggy in the Spectrum ROM, by the way). I've investigated a bit further, and this code also crashes the same way, and it's much simpler: Code: DIM i as Uinteger Removing s = "" makes the program to take longer to crash. I guess this is related to the str( ) function. But need more work :? Re: Screen corruption & possible crash - LCD - 11-13-2010 But at least, you know where it sits, the nasty bug. This means, there is a chance o fix it. OK, it is buggy in Spectrum ROM, but it does not crash like that. Is there a special prize for finding nasty bugs, except beating until the guy who reported this bug forgets about this bug? Okay, I could shorten my bugtest source code a little bit, but I took it directly from a game which I write, and reduced it quickly a little bit to show what happens, just to be the first who reports it Re: Screen corruption & possible crash - boriel - 11-14-2010 It seems already fixed. Can you download the new fresh version 1.2.6-r1605 and try it? It is working to me now. Re: Screen corruption & possible crash - LCD - 11-15-2010 boriel Wrote:It seems already fixed.That was *Fast*. Thank you! Today it is too late, but I will check it as soon as possible, probably tomorrow (Probably, because tomorrow I'm in the court in case of my broken leg). Re: Screen corruption & possible crash - boriel - 11-15-2010 In court???? hock: I knew you broke your leg, but why going to court? Anyway: It was the STR$ function. Note that VAL() also had this bug and has been fixed. Re: Screen corruption & possible crash - LCD - 11-15-2010 boriel Wrote:In court???? hock: I knew you broke your leg, but why going to court?Because of months of pain (I still have pains when the weather changes). And the guy who is responsible for this even started to tell the witness lies about me. This will not be forgiven. It was a accident, so I wanted him to pay medicament costs, but now the situation changed apruptly after this. boriel Wrote:Anyway: It was the STR$ function. Note that VAL() also had this bug and has been fixed.Oh, good, so one bugreport and two fixes. Maybe you know it already: You are great! Edit: Tested, this bug is exterminated. It works now as expected. Big thanx to Boriel and good night. The thread can be closed now. |