[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#23763: Bug report: Grep stops, if a text file contains a null charac
From: |
Eric Blake |
Subject: |
bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes |
Date: |
Wed, 15 Jun 2016 12:37:34 -0600 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 |
On 06/15/2016 12:29 PM, Paul Eggert wrote:
> sur-behoffski wrote:
>> Are there documentation standards, especially GNU ones, that cover this
>> distinction? If not, is it worth striving to gradually introduce this
>> in a systematic manner, e.g. "NUL (the zero character)"?
>
> I don't know of any terminology standards in this area. (Wikipedia does
> not count. :-)
The POSIX standard tries to consistently use NUL for the character name
(whether you are using a unibyte encoding and it fits in char, or a wide
encoding where it fits in wchar_t), a 'null byte' for a byte that is all
zeroes (which happens to be the NUL character in both unibyte and in
multibyte encodings, since no other multibyte character is allowed to
have an embedded null byte), and a 'null pointer' when referring to a
pointer to nowhere (the constant NULL is a null pointer, as is the C
expression '((void*)0)', although the null pointer need not have an
all-zero bit representation in hardware).
http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html
in particular 3.243-3.245
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Bjoern Voigt, 2016/06/13
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Eric Blake, 2016/06/13
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Bjoern Voigt, 2016/06/13
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Paul Eggert, 2016/06/13
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Bjoern Voigt, 2016/06/14
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Paul Eggert, 2016/06/14
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Bjoern Voigt, 2016/06/14
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Paul Eggert, 2016/06/15
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, sur-behoffski, 2016/06/15
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes, Paul Eggert, 2016/06/15
- bug#23763: Bug report: Grep stops, if a text file contains a null character after 32768 bytes,
Eric Blake <=