mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-03-06 01:40:22 -05:00
term: get_font_dpi(): don't crash when there aren't any available monitors
Seen on plasma; monitor is turned off, and then back on again. Before the "new" output global is emitted, the compositor calls fractional_scale::preferred_scale(). This results in a call to get_font_dpi(), where we crash, since it assumes there is at least one monitor available. Fix by falling back to a DPI of 96. Hopefully closes #1498
This commit is contained in:
parent
400a3f5ad2
commit
b95a7cb84f
2 changed files with 6 additions and 2 deletions
|
|
@ -106,11 +106,15 @@
|
|||
auto-detection ([#1465][1465]).
|
||||
* Crash when `XDG_ACTIVATION_TOKEN` is set, but compositor does not
|
||||
support XDG activation ([#1493][1493]).
|
||||
* Crash when compositor calls `fractional_scale::preferred_scale()`
|
||||
when there are no monitors (for example, after a monitor has been
|
||||
turned off and then back on again) ([#1498][1498]).
|
||||
|
||||
[1436]: https://codeberg.org/dnkl/foot/issues/1436
|
||||
[1464]: https://codeberg.org/dnkl/foot/issues/1464
|
||||
[1465]: https://codeberg.org/dnkl/foot/issues/1465
|
||||
[1493]: https://codeberg.org/dnkl/foot/pulls/1493
|
||||
[1498]: https://codeberg.org/dnkl/foot/issues/1498
|
||||
|
||||
|
||||
### Security
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue