lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1406750412.12100.65.camel@joe-AO725>
Date:	Wed, 30 Jul 2014 13:00:12 -0700
From:	Joe Perches <joe@...ches.com>
To:	Arjun Sreedharan <arjun024@...il.com>
Cc:	rjw@...ysocki.net, lenb@...nel.org, linux-acpi@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] ACPI: fix test for hex digit.

On Thu, 2014-07-31 at 01:22 +0530, Arjun Sreedharan wrote:
> decimal 0 is ascii for NULL. Hex digit matching should be from '0'
> (decimal 30 of ascii) to '9' and 'A' to 'F'.
> Unfixed version returns true for #,$,%,& etc.
[]
> diff --git a/drivers/acpi/acpi_pnp.c b/drivers/acpi/acpi_pnp.c
[]
> @@ -322,7 +322,7 @@ static const struct acpi_device_id acpi_pnp_device_ids[] = {
>  
>  static bool is_hex_digit(char c)
>  {
> -	return (c >= 0 && c <= '9') || (c >= 'A' && c <= 'F');
> +	return (c >= '0' && c <= '9') || (c >= 'A' && c <= 'F');
>  }

Maybe delete this and do s/is_hex_digit/isxdigit/ ?


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ