summaryrefslogtreecommitdiff
path: root/gpsmon.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2013-10-10 07:06:37 -0400
committerEric S. Raymond <esr@thyrsus.com>2013-10-10 07:06:37 -0400
commit8fe81791aa9e317bcedf940918e5d3d9bdd19ed3 (patch)
tree1eb386eea66df3fc0b70f6e7d88456129a9f508e /gpsmon.c
parent0ed25db32c0864d4000e1d7c3ce1836fdf37f806 (diff)
downloadgpsd-8fe81791aa9e317bcedf940918e5d3d9bdd19ed3.tar.gz
Minor command-handling fix.
Diffstat (limited to 'gpsmon.c')
-rw-r--r--gpsmon.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/gpsmon.c b/gpsmon.c
index 7ea716d8..5e3eb86d 100644
--- a/gpsmon.c
+++ b/gpsmon.c
@@ -455,7 +455,7 @@ static bool do_command(void)
int status;
ssize_t len;
- (void)wmove(cmdwin, 0, (int)promptlen + 2);
+ (void)wmove(cmdwin, 0, (int)promptlen);
(void)wrefresh(cmdwin);
(void)echo();
/*@ -usedef -compdef @*/
@@ -479,6 +479,7 @@ static bool do_command(void)
} else
arg = line + 1;
+ /* handle it in the currently selected monitor object if possible */
if (serial && active != NULL && (*active)->command != NULL) {
status = (*active)->command(line);
if (status == COMMAND_TERMINATE)
@@ -487,6 +488,8 @@ static bool do_command(void)
return true;
assert(status == COMMAND_UNKNOWN);
}
+
+ /* otherse dispatch to generic commands */
switch (line[0]) {
#ifdef RECONFIGURE_ENABLE
case 'c': /* change cycle time */