Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

uio-howto: example bug

Bug in demo program, checking wrong return value

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Cc: "Hans J. Koch" <hjk@hansjkoch.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Stephen Hemminger and committed by
Greg Kroah-Hartman
93ce83b6 25c22d5b

+1 -1
+1 -1
Documentation/DocBook/uio-howto.tmpl
··· 984 984 return errno; 985 985 } 986 986 configfd = open(&quot;/sys/class/uio/uio0/device/config&quot;, O_RDWR); 987 - if (uiofd &lt; 0) { 987 + if (configfd &lt; 0) { 988 988 perror(&quot;config open:&quot;); 989 989 return errno; 990 990 }