HomeFreeBSD

libnvpair.c: replace strstr() with strchr() for a single character

Description

libnvpair.c: replace strstr() with strchr() for a single character

Since we're looking for a single new-line character in the haystack,
it's better (and slightly more efficient) to use strchr() instead of
strstr().

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Richard Yao <richard.yao@alumni.stonybrook.edu>
Signed-off-by: rilysh <nightquick@proton.me>
Closes #15798

Details

Provenance
rilysh <nightquick@proton.me>Authored on Jan 29 2024, 5:46 PM
GitHub <noreply@github.com>Committed on Jan 29 2024, 5:46 PM
Parents
rGc3fd7a52173c: Update man pages to time(1) from time(2)
Branches
Unknown
Tags
Unknown