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>
(cherry picked from commit 1a01e96c6d
)
This commit is contained in:
parent
e8a45d97d3
commit
5fc34f65f7
|
@ -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) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user