xenfb.c: avoid expensive loops when prod <= out_cons
If the frontend sets out_cons to a value higher than out_prod, it will cause xenfb_handle_events to loop about 2^32 times. Avoid that by using better checks at the beginning of the function. Signed-off-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com> Reported-by: NLing Liu <liuling-it@360.cn>
Showing
想要评论请 注册 或 登录