summaryrefslogtreecommitdiff
path: root/serial.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2015-01-29 15:05:09 -0500
committerEric S. Raymond <esr@thyrsus.com>2015-01-29 15:05:09 -0500
commitee40d6733bcd312576c9223de6adaf16f1e0cfd2 (patch)
tree5b1cd375f79082756a56293e8256558e5520333b /serial.c
parent646f855d4cdd6d7c27333d511b1d49eaea277af4 (diff)
downloadgpsd-ee40d6733bcd312576c9223de6adaf16f1e0cfd2.tar.gz
Alas, we can't use ICANON.
For the moment, we do nothing with the textual argument to gpsd_optimize_io(). We'd like to use it to set ICANON mode and let the kernel do all the line buffering itself. The problem with this is that VTIME stops working in ICANON, so a binary packet coming up the wire would result in no further input being seen.
Diffstat (limited to 'serial.c')
-rw-r--r--serial.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/serial.c b/serial.c
index 4655cc24..74e339b8 100644
--- a/serial.c
+++ b/serial.c
@@ -626,7 +626,11 @@ void gpsd_optimize_io(struct gps_device_t *session,
* either accumulated characters corresponding to the minimum
* possible length of a packet or timed out.
*
- * FIXME: Use cooked I/O for textual packets.
+ * For the moment, we do nothing with the textual flag. We'd like
+ * to use it to set ICANON mode and let the kernel do all the line
+ * buffering itself. The problem with this is that VTIME stops
+ * working in ICANON mode, so a binary packet coming up the wire
+ * would result in no further input being seen.
*/
if (minlength > 1) {
session->ttyset.c_cc[VMIN] = minlength;