/* This call is similar to hwconfig_arg_cmp, except that it takes an additional argument @subopt, and so works with sub-options.  */
int hwconfig_subarg_cmp(const char *opt, const char *subopt, const char *subarg)
/* This call is similar to hwconfig_arg_cmp, except that it takes an additional argument @subopt, and so works with sub-options.  */
int hwconfig_subarg_cmp(const char *opt, const char *subopt, const char *subarg)
{
	const char *argstr;
	size_t arglen;
	argstr = hwconfig_subarg(opt, subopt, &arglen);
	if (!argstr || arglen != strlen(subarg))
		return 0;
	return !strncmp(argstr, subarg, arglen);
}