[Pdbg] [PATCH 6/8] pdbg: Define common command/flag argument parsers

Alistair Popple alistair at popple.id.au
Mon Jun 25 16:04:30 AEST 2018


> > +	errno = 0;
> > +	tmp = strtoul(argv, &endptr, 0);
> > +	if (errno || *endptr != '\0' || tmp > (uint32_t) -1UL)
> 
> What about using UINT32_MAX instead of '(uint32_t)  -1UL'?

Good idea! Thanks.

- Alistair



More information about the Pdbg mailing list