aboutsummaryrefslogtreecommitdiff
path: root/advtrains/debugringbuffer.lua
diff options
context:
space:
mode:
authororwell96 <orwell@bleipb.de>2021-01-02 18:00:12 +0100
committerorwell96 <orwell@bleipb.de>2021-02-10 16:39:46 +0100
commit8f4c90c5a53b531451436b8e0a1ea8a3b750110e (patch)
treea347eddc1ec522eb083430417f79c129cde2ddfc /advtrains/debugringbuffer.lua
parent3c42d87dc0b4b3aed454e68541bff711dba75dc9 (diff)
downloadadvtrains-8f4c90c5a53b531451436b8e0a1ea8a3b750110e.tar.gz
advtrains-8f4c90c5a53b531451436b8e0a1ea8a3b750110e.tar.bz2
advtrains-8f4c90c5a53b531451436b8e0a1ea8a3b750110e.zip
Add debug prints, modify LZB to fix problems with look_ahead
Diffstat (limited to 'advtrains/debugringbuffer.lua')
-rw-r--r--advtrains/debugringbuffer.lua5
1 files changed, 4 insertions, 1 deletions
diff --git a/advtrains/debugringbuffer.lua b/advtrains/debugringbuffer.lua
index 704c0c5..bdb4a3a 100644
--- a/advtrains/debugringbuffer.lua
+++ b/advtrains/debugringbuffer.lua
@@ -24,7 +24,10 @@ function advtrains.drb_dump(tid)
return
end
repeat
- atdebug(ringbufs[tid][ringbufcnt[tid]])
+ local t = ringbufs[tid][ringbufcnt[tid]]
+ if t then
+ atdebug(t)
+ end
ringbufcnt[tid]=ringbufcnt[tid]+1
if ringbufcnt[tid] > ringbuflen then
ringbufcnt[tid]=0