MCPcopy Create free account
hub / github.com/Genivia/ugrep / check_binary

Function check_binary

src/ugrep.cpp:717–720  ·  view source on GitHub ↗

return true if -X or if -W and match s[0..n-1] is binary

Source from the content-addressed store, hash-verified

715
716// return true if -X or if -W and match s[0..n-1] is binary
717inline bool check_binary(const char *s, size_t n)
718{
719 return (flag_hex || (flag_with_hex && is_binary(s, n)));
720}
721
722// check if a file's inode is the current output file, to avoid searching the file we write to
723inline bool is_output(ino_t inode)

Callers 5

operator()Method · 0.85
operator()Method · 0.85
operator()Method · 0.85
operator()Method · 0.85
searchMethod · 0.85

Calls 1

is_binaryFunction · 0.70

Tested by

no test coverage detected