forked from enlightenment/enlightenment
parent
ea8f8c3a75
commit
a0ae01c227
|
@ -22,13 +22,14 @@ _bl_write_file(const char *file, int val)
|
||||||
perror("open");
|
perror("open");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
snprintf(buf, sizeof(buf), "%i", val);
|
snprintf(buf, sizeof(buf), "%d", val);
|
||||||
if (write(fd, buf, strlen(buf)) != (int)strlen(buf))
|
if (write(fd, buf, strlen(buf)) != (int)strlen(buf))
|
||||||
{
|
{
|
||||||
perror("write");
|
perror("write");
|
||||||
close(fd);
|
close(fd);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
fprintf(stderr, "BACKLIGHT: %s -> %d", file, val);
|
||||||
close(fd);
|
close(fd);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue