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.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/noncore/apps/opie-console/io_serial.cpp b/noncore/apps/opie-console/io_serial.cpp index cc63c58..e6d1688 100644 --- a/noncore/apps/opie-console/io_serial.cpp +++ b/noncore/apps/opie-console/io_serial.cpp | |||
@@ -1,24 +1,25 @@ | |||
1 | |||
1 | #include <fcntl.h> | 2 | #include <fcntl.h> |
2 | #include <termios.h> | 3 | #include <termios.h> |
3 | #include <errno.h> | 4 | #include <errno.h> |
4 | #include <unistd.h> | 5 | #include <unistd.h> |
5 | #include "io_serial.h" | 6 | #include "io_serial.h" |
6 | 7 | ||
7 | IOSerial::IOSerial(const Profile &config) : IOLayer(config) { | 8 | IOSerial::IOSerial(const Profile &config) : IOLayer(config) { |
8 | m_read = 0l; | 9 | m_read = 0l; |
9 | m_error = 0l; | 10 | m_error = 0l; |
10 | m_fd = 0; | 11 | m_fd = 0; |
11 | m_connected = false; | 12 | m_connected = false; |
12 | reload(config); | 13 | reload(config); |
13 | } | 14 | } |
14 | 15 | ||
15 | 16 | ||
16 | IOSerial::~IOSerial() { | 17 | IOSerial::~IOSerial() { |
17 | if (m_fd) { | 18 | if (m_fd) { |
18 | close(); | 19 | close(); |
19 | } | 20 | } |
20 | } | 21 | } |
21 | 22 | ||
22 | void IOSerial::send(const QByteArray &data) { | 23 | void IOSerial::send(const QByteArray &data) { |
23 | if (m_fd) { | 24 | if (m_fd) { |
24 | write(m_fd, data.data(), data.size()); | 25 | write(m_fd, data.data(), data.size()); |