man grep:
-Z, --null
Output a zero byte (the ASCII NUL character) instead of the character that normally
follows a file name. For example, grep -lZ outputs a zero byte after each file name
instead of the usual newline. This option makes the output unambiguous, even in the
presence of file names containing unusual characters like newlines. This option can be
used with commands like find -print0, perl -0, sort -z, and xargs -0 to process
arbitrary file names, even those that contain newline characters.
-z, --null-data
Treat the input as a set of lines, each terminated by a zero byte (the ASCII NUL
character) instead of a newline. Like the -Z or --null option, this option can be used
with commands like sort -z to process arbitrary file names.
man xargs: --null
-0 Input items are terminated by a null character instead of by whitespace, and the quotes
and backslash are not special (every character is taken literally). Disables the end of
file string, which is treated like any other argument. Useful when input items might
contain white space, quote marks, or backslashes. The GNU find -print0 option produces
input suitable for this mode.
man find: -print0
True; print the full file name on the standard output, followed by a null character
(instead of the newline character that -print uses). This allows file names that con‐
tain newlines or other types of white space to be correctly interpreted by programs that
process the find output. This option corresponds to the -0 option of xargs.