MCPcopy Create free account
hub / github.com/coreutils/coreutils / size_opt

Function size_opt

src/uniq.c:244–252  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

242 invalid. Silently convert too-large values to IDX_MAX. */
243
244static idx_t
245size_opt (char const *opt, char const *msgid)
246{
247 intmax_t size;
248 if (LONGINT_OVERFLOW < xstrtoimax (opt, NULL, 10, &size, "")
249 || size < 0)
250 error (EXIT_FAILURE, 0, "%s: %s", opt, _(msgid));
251 return MIN (size, IDX_MAX);
252}
253
254static bool
255newline_or_blank (mcel_t g)

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected