libtextstyle: Turn off hyperlinks on the Solaris console.

The Solaris 11 console prints garbage when a hyperlink is output.
Tested on Solaris 11.4/x86 and Solaris 11 OmniOS/x86.

* libtextstyle/gnulib-local/lib/term-ostream.oo.c (should_enable_hyperlinks):
Return false for the Solaris console.
This commit is contained in:
Bruno Haible 2023-02-13 23:05:20 +01:00
parent 9dd607e866
commit 12cf1769ca

View File

@ -1,5 +1,5 @@
/* Output stream for attributed text, producing ANSI escape sequences.
Copyright (C) 2006-2008, 2017, 2019-2020, 2022 Free Software Foundation, Inc.
Copyright (C) 2006-2008, 2017, 2019-2020, 2022-2023 Free Software Foundation, Inc.
Written by Bruno Haible <bruno@clisp.org>, 2006.
This program is free software: you can redistribute it and/or modify
@ -2354,6 +2354,15 @@ should_enable_hyperlinks (const char *term)
return !known_buggy;
}
}
/* Solaris console.
Program | TERM | Supports hyperlinks?
-----------------------------------+-----------+---------------------------
Solaris kernel's terminal emulator | sun-color | produces garbage
SPARC PROM's terminal emulator | sun | ?
*/
if (strcmp (term, "sun") == 0 || strcmp (term, "sun-color") == 0)
return false;
}
/* In case of doubt, enable hyperlinks. So this code does not need to change