xstrto.h File Reference
This graph shows which files directly or indirectly include this file:
![](xstrto_8h__dep__incl.png)
Go to the source code of this file.
Functions | |
bool | xstrtoui (const char *s, char **end, unsigned int *value, unsigned int min, unsigned int max) |
Function Documentation
◆ xstrtoui()
bool xstrtoui | ( | const char * | s, |
char ** | end, | ||
unsigned int * | value, | ||
unsigned int | min, | ||
unsigned int | max | ||
) |
Convert a c-string (or its prefix) into an unsigned integer.
- Parameters
-
s input string end like strtoul's "end" pointer value pointer for result. Undefined on failure min minimum accepted value max maximum accepted value
If @end is nullptr, we assume the caller wants a "strict strtoul", and hence "15a" is rejected. In either case, the value obtained is compared for min-max compliance. Base is always 0, i.e. autodetect depending on @s.
- Returns
- true/false whether number was accepted. On failure, *value has undefined contents.
Definition at line 86 of file xstrto.cc.
References max(), min(), and xstrtoul().
Referenced by parse_acl_tos(), Ip::Qos::Config::parseConfigLine(), and process_options().
Introduction
- About Squid
- Why Squid?
- Squid Developers
- How to Donate
- How to Help Out
- Getting Squid
- Squid Source Packages
- Squid Deployment Case-Studies
- Squid Software Foundation
Documentation
- Quick Setup
- Configuration:
- FAQ and Wiki
- Guide Books:
- Non-English
- More...
Support
- Security Advisories
- Bugzilla Database
- Mailing lists
- Contacting us
- Commercial services
- Project Sponsors
- Squid-based products