On many systems the device nodes will not be writable normally. There
is no reason to open for writing in any case. Also switched back to
non-blocking I/O.
Change-Id: I9290e6b1ce7e3bc6cb0e75069b3968f647ffbeee
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
#endif
int fd;
- fd = qt_safe_open(device.toLocal8Bit().constData(), O_RDWR, 0);
+ fd = qt_safe_open(device.toLocal8Bit().constData(), O_RDONLY | O_NDELAY, 0);
if (fd >= 0) {
if (repeatDelay > 0 && repeatRate > 0) {
int kbdrep[2] = { repeatDelay, repeatRate };