Closed KaylebJay closed 5 months ago
The quick but wrong fix is truncating the length of "self.bitmap" to match expectations here:
... but that would only hide some underlying bug. If you're running a server, you probably want the quick fix. To do a real fix, I need a way to reproduce. Also, do you use a modified version of ggraffiti?
I do use a slightly modified version of ggraffiti, but nothing is changed except a few items are de-registered, and a few other items are registered.
You could test our live deployment of ggraffiti on the server- it's the server Tunnelers' Abyss. We could do the quick fix, but really the stranger thing would be how 1040 bytes could appear there anyways - it's a bug, but I only wish I knew how to reproduce it.
Can I find the source code somewhere? Who knows, maybe your custom canvas nodes are related to #11.
I don't want to spend time farming materials on that server just to find out whether I can reproduce a bug. If I can reproduce the bug, I'd like to be able to debug it.
Sure, what is your username on Gitlab? I'll add you to our repo
A user of my mod Blood Splatter (uses this mod as a base) got it too. https://content.minetest.net/threads/8287/ There must be something wrong with the math. I think bitmap data is only manipulated in canvas. Maybe it's indexing too far in drawrect or drawpixel and thus adding to it? In his case it was 1088 bytes which means one row got added somehow (16x17 image) but in this issue it's different so it varies.
Sure, what is your username on Gitlab? I'll add you to our repo
Nice, I am https://gitlab.com/grorp
I did some testing (https://github.com/grorp/ggraffiti/commit/17c004a40efb66fd74a5074484a10eb109608bc6) and the only case where the bitmap should be able to get an incorrect length is with an out-of-bounds CanvasEntity:draw_pixel
call. I don't know how this can happen, but I added a bounds check to draw_pixel
. I hope that fixes the error. Please test again.
ContentDB user ClassicAdam ran Blood Splatter for 6 hours and had no crashes with the bounds check. https://content.minetest.net/threads/8287/
I've now deployed the changes on our server, will let you know how it goes. I also added you to our repo, btw :)
I haven't seen this issue again, so I'm closing this issue for now - if it comes back up I'll reopen. Thank you!