summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-console/io_serial.cpp
Side-by-side diff
Diffstat (limited to 'noncore/apps/opie-console/io_serial.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-console/io_serial.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/noncore/apps/opie-console/io_serial.cpp b/noncore/apps/opie-console/io_serial.cpp
index 929aeff..845f4be 100644
--- a/noncore/apps/opie-console/io_serial.cpp
+++ b/noncore/apps/opie-console/io_serial.cpp
@@ -154,13 +154,13 @@ int IOSerial::baud(int baud) const {
void IOSerial::errorOccured() {
emit error(ClosedUnexpected, strerror(errno));
close();
}
void IOSerial::dataArrived() {
- QByteArray array(4096);
+ QByteArray array(4097);
int len = read(m_fd, array.data(), 4096);
if (len == 0)
close();
if (len < 0)
return;
@@ -172,6 +172,11 @@ QString IOSerial::identifier() const {
return "serial";
}
QString IOSerial::name() const {
return "RS232 Serial IO Layer";
}
+int IOSerial::rawIO()const {
+ int fd = ::open(m_device, O_RDWR );
+
+ return fd;
+};