Open 3BD-R opened 2 years ago
I have also discovered this whilst debugging my own DWM instance. Any imbalance with closing ^
cause the program to keep reading until a ^
is encountered, even if this means reading memory which is outside of the buffer, resulting in a segfault crash. A simple fix would be to check the number of ^
BEFORE the null char \0
at the end of stext and, if that number is odd, default to the original "dwm-"VERSION
status text and perhaps log the error to stdout/stderr. This defaulting to the string is also seen when setting stext to "" (xsetroot -name ""
so it should be consistent with other fixes. Ill make a pull request shortly once i have tested my implementation
Hi, @3BD-R Thanks you very much for your grateful thanks :) and thanks for your feedback on issues. I will check to implement the @nick-1666 fix as soon as possible.
best regards, 6π
this patch is awesome thanks for your efforts, the issue or bug is when miss typing one of
^
signs the wm crashes and log me out example:xsetroot -name "^c#FF0000 example"
, I know it is wrong implementation but the result was crash