Fix variable check in sparc clock frequency probing.

* sysdeps/unix/sysv/linux/sparc/sparc64/get_clockfreq.c
	(__get_clockfreq_via_proc_openprom): Fix test on wrong variable.
This commit is contained in:
Antoine Balestrat 2012-04-13 14:31:35 -07:00 committed by David S. Miller
parent a9e8e0e0f3
commit c7a6ab72e9
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2012-04-13 Antoine Balestrat <merkil33@gmail.com>
* sysdeps/unix/sysv/linux/sparc/sparc64/get_clockfreq.c
(__get_clockfreq_via_proc_openprom): Fix test on wrong variable.
2012-04-13 Chris Leonard <cjlhomeaddress@gmail.com>
[BZ #13973]

View File

@ -126,7 +126,7 @@ __get_clockfreq_via_proc_openprom (void)
__stpcpy (prop, "/clock-frequency");
clkfreq_fd = open (node, O_RDONLY);
if (fd != -1)
if (clkfreq_fd != -1)
{
if (read (clkfreq_fd, type_string,
sizeof (type_string)) > 0)