mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-31 17:31:11 +02:00
dt.cfix logic error
Origin commit data
------------------
Branch: ni/coolstream
Commit: 2074dc4a5d
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2015-01-28 (Wed, 28 Jan 2015)
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
4
src/dt.c
4
src/dt.c
@@ -129,14 +129,14 @@ int main(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
else if (sscanf(argv[x], "-ls%X", &b) == 1)
|
else if (sscanf(argv[x], "-ls%X", &b) == 1)
|
||||||
{
|
{
|
||||||
if ((b > 0) || (b <= 8)) {
|
if ((b > 0) && (b <= 8)) {
|
||||||
if (ioctl(fd, IOC_FP_LED_CTRL, b | 0x80))
|
if (ioctl(fd, IOC_FP_LED_CTRL, b | 0x80))
|
||||||
perror("IOC_FP_LED_CTRL");
|
perror("IOC_FP_LED_CTRL");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (sscanf(argv[x], "-lc%X", &b) == 1)
|
else if (sscanf(argv[x], "-lc%X", &b) == 1)
|
||||||
{
|
{
|
||||||
if ((b > 0) || (b <= 8)) {
|
if ((b > 0) && (b <= 8)) {
|
||||||
if (ioctl(fd, IOC_FP_LED_CTRL, b))
|
if (ioctl(fd, IOC_FP_LED_CTRL, b))
|
||||||
perror("IOC_FP_LED_CTRL");
|
perror("IOC_FP_LED_CTRL");
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user