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

Function parse_n_units

src/split.c:1376–1383  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1374 Return the number parsed, or an INTMAX_MAX on overflow. */
1375
1376static intmax_t
1377parse_n_units (char const *arg, char const *multipliers, char const *msgid)
1378{
1379 intmax_t n;
1380 if (OVERFLOW_OK < xstrtoimax (arg, NULL, 10, &n, multipliers) || n < 1)
1381 strtoint_die (msgid, arg);
1382 return n;
1383}
1384
1385/* Parse K/N syntax of chunk options. */
1386

Callers 2

parse_chunkFunction · 0.85
mainFunction · 0.85

Calls 1

strtoint_dieFunction · 0.85

Tested by

no test coverage detected