Hi, On 2024-01-04 17:11, Krzysztof Żelechowski wrote: > So we have conflicting information here. > 1. The character '\0' is the end of a string.
This is the basic of the C language. It has nothing to do with the GNU libc. > 2. The character ']' is the end of this scan set. > Information (2) is more specific than information (1), and a format string > is not a normal string, and a scan set is not a substring but a data > island embedded within a string (for example, the format specifier > "%[\1-\377]" is valid as a format string but invalid as a string under > UTF—8 locale). Therefore it is natural to assume that rule (2) should > prevail. Since it apparently does not, this oddity should be documented. I disagree there. This documentation is about the GNU C library, not a basic C course. Regards Aurelien -- Aurelien Jarno GPG: 4096R/1DDD8C9B aurel...@aurel32.net http://aurel32.net