mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-24 10:14:52 +00:00
Return a valid X error when stuck in font alias loop
Part of fix for Sun bug 4258475 <http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=4258475>
This commit is contained in:
@@ -302,8 +302,14 @@ doOpenFont(ClientPtr client, OFclosurePtr c)
|
||||
c->fontname = newname;
|
||||
c->fnamelen = newlen;
|
||||
c->current_fpe = 0;
|
||||
if (--aliascount <= 0)
|
||||
if (--aliascount <= 0) {
|
||||
/* We've tried resolving this alias 20 times, we're
|
||||
* probably stuck in an infinite loop of aliases pointing
|
||||
* to each other - time to take emergency exit!
|
||||
*/
|
||||
err = BadImplementation;
|
||||
break;
|
||||
}
|
||||
continue;
|
||||
}
|
||||
if (err == BadFontName) {
|
||||
|
||||
Reference in New Issue
Block a user