1
0
Fork 0
mirror of https://github.com/NickHu/sway synced 2025-01-17 18:12:41 +01:00

Replace unprintable characters in input device id

This commit is contained in:
wb9688 2019-12-31 18:31:45 +01:00 committed by Simon Ser
parent b5a35c484f
commit 17ff13fc84

View file

@ -70,7 +70,8 @@ char *input_device_get_identifier(struct wlr_input_device *device) {
char *p = name;
for (; *p; ++p) {
if (*p == ' ') {
// There are in fact input devices with unprintable characters in its name
if (*p == ' ' || !isprint(*p)) {
*p = '_';
}
}