mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-10-25 08:11:38 +00:00
DisplayIter::next_screen built the monitor iterator from the xcb_randr_get_monitors reply and freed the reply on the next line. The iterator's data pointer points into that reply, so next() read every monitor's name atom, position and size from freed memory, and xcb_randr_monitor_info_next() walked it too. Keep the reply with the iterator and free it when moving to the next screen or when the DisplayIter is dropped.