MCPcopy Create free account
hub / github.com/antirez/ds4 / parse_float_range

Function parse_float_range

ds4_agent.c:466–474  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

464 }
465 return (int)v;
466}
467
468static int parse_nonnegative_int(const char *s, const char *opt) {
469 char *end = NULL;
470 long v = strtol(s, &end, 10);
471 if (s[0] == '\0' || *end != '\0' || v < 0 || v > INT32_MAX) {
472 fprintf(stderr, "ds4-agent: invalid value for %s: %s\n", opt, s);
473 exit(2);
474 }
475 return (int)v;
476}
477

Callers 1

parse_optionsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected