Client: TomeNET 4.7.2 for Linux (amd64), complete (sound and music pack included) (147 MB)
Steps to reproduce:
0) Loged in, standing int town.
1) Take a screenshot (^T)
Expected behaviour:
Message about screenshot taken, game continues.
Current behaviour:
Client crashes with no message
Note: I tink I was able to take screenshot while in some menu, it always crashed in game.
Temporary solution: Don't take screenshots, put any other macro on ^T key to avoid accidental triggering.
Taking screenshot (sometimes) crashes client [Linux client 4.7.2]
Re: Taking screenshot (sometimes) crashes client [Linux client 4.7.2]
Found the bug, made a fix - https://github.com/jezek/tomenet-src/co ... 80e4750ede
Last edited by jezek on Sun Apr 05, 2020 3:52 pm, edited 1 time in total.
Re: Taking screenshot (sometimes) crashes client [Linux client 4.7.2]
I think you meant to link this commit: https://github.com/jezek/tomenet/commit ... 1bcdc1d2c0
Some of the changes are a bit unnecessary. color_table variable doesn't really need to be renamed. The actual bug seems to be the use of sizeof. You should use the N_ELEMENTS macro from common/defines.h instead of writing it out as sizeof(str_color_table)/sizeof(str_color_table[0]). I think only two lines need to be changed. You can add a comment somewhere if you like.
Some of the changes are a bit unnecessary. color_table variable doesn't really need to be renamed. The actual bug seems to be the use of sizeof. You should use the N_ELEMENTS macro from common/defines.h instead of writing it out as sizeof(str_color_table)/sizeof(str_color_table[0]). I think only two lines need to be changed. You can add a comment somewhere if you like.
Re: Taking screenshot (sometimes) crashes client [Linux client 4.7.2]
Yes, you are right, I misspasted the link... and you are also right about the variable name change + macro stuff (didn't know bout the macro)... there were really only two line changes with the macro usage...
sorry, all my fault due to noobiness
this commit will do it ![Wink ;)](./images/smilies/icon_e_wink.gif)
https://github.com/jezek/tomenet-src/co ... ff=unified
sorry, all my fault due to noobiness
![Wink ;)](./images/smilies/icon_e_wink.gif)
![Wink ;)](./images/smilies/icon_e_wink.gif)
https://github.com/jezek/tomenet-src/co ... ff=unified
Last edited by jezek on Sun Apr 05, 2020 3:53 pm, edited 1 time in total.
Re: Taking screenshot (sometimes) crashes client [Linux client 4.7.2]
This one has now also been cherry-picked. Thanks for the fix.