summaryrefslogtreecommitdiff
path: root/serial.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2015-03-10 16:25:44 -0400
committerEric S. Raymond <esr@thyrsus.com>2015-03-10 16:25:44 -0400
commitfcdc943a250c8789176f3628f6b094bed8d395ec (patch)
treec6cf645b27676a3ed62a712bbb38402f70ce039d /serial.c
parent9b75c8573665113ac7cda15843c3ce5c0ccc8bdd (diff)
downloadgpsd-fcdc943a250c8789176f3628f6b094bed8d395ec.tar.gz
Include path in faInclude path in file open failure messages.
Diffstat (limited to 'serial.c')
-rw-r--r--serial.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/serial.c b/serial.c
index 6e51ba95..8f287869 100644
--- a/serial.c
+++ b/serial.c
@@ -464,18 +464,21 @@ int gpsd_serial_open(struct gps_device_t *session)
if ((session->gpsdata.gps_fd =
open(session->gpsdata.dev.path, (int)(mode | O_NONBLOCK | O_NOCTTY))) == -1) {
gpsd_log(&session->context->errout, LOG_ERROR,
- "device open failed: %s - retrying read-only\n",
+ "device open of %s failed: %s - retrying read-only\n",
+ session->gpsdata.dev.path,
strerror(errno));
if ((session->gpsdata.gps_fd =
open(session->gpsdata.dev.path, O_RDONLY | O_NONBLOCK | O_NOCTTY)) == -1) {
gpsd_log(&session->context->errout, LOG_ERROR,
- "read-only device open failed: %s\n",
+ "read-only device open of %s failed: %s\n",
+ session->gpsdata.dev.path,
strerror(errno));
return -1;
}
gpsd_log(&session->context->errout, LOG_PROG,
- "file device open success: %s\n",
+ "file device open of %s succeeded: %s\n",
+ session->gpsdata.dev.path,
strerror(errno));
}
}