input_method: Print misunderstood flags

This commit is contained in:
Dorota Czaplejewicz
2019-12-19 12:24:07 +00:00
parent e9d6631159
commit 4d487ed872

View File

@ -102,8 +102,12 @@ pub mod c {
imservice.pending = IMProtocolState { imservice.pending = IMProtocolState {
content_hint: { content_hint: {
ContentHint::from_bits(hint).unwrap_or_else(|| { ContentHint::from_bits(hint).unwrap_or_else(|| {
eprintln!("Warning: received invalid hint flags"); let out = ContentHint::from_bits_truncate(hint);
ContentHint::NONE eprintln!(
"Warning: received hint flags with unknown bits set: 0x{:x}",
hint ^ out.bits(),
);
out
}) })
}, },
content_purpose: { content_purpose: {