check whether a user-supplied option string is a proper leading substring of a particular option name; option string might have a colon or equals sign and arbitrary value appended to it */
| 1250 | substring of a particular option name; option string might have |
| 1251 | a colon or equals sign and arbitrary value appended to it */ |
| 1252 | boolean |
| 1253 | match_optname(const char *user_string, const char *optn_name, int min_length, |
| 1254 | boolean val_allowed) |
| 1255 | { |
| 1256 | int len = (int) strlen(user_string); |
| 1257 | |
| 1258 | if (val_allowed) |
| 1259 | len = length_without_val(user_string, len); |
| 1260 | |
| 1261 | return (boolean) (len >= min_length |
| 1262 | && !strncmpi(optn_name, user_string, len)); |
| 1263 | } |
| 1264 | |
| 1265 | staticfn void |
| 1266 | usage(int argc UNUSED, char **argv) |
nothing calls this directly
no test coverage detected