X-Git-Url: http://git.archive.openwrt.org/?p=project%2Fugps.git;a=blobdiff_plain;f=nmea.c;fp=nmea.c;h=4d9cb902eae294db159cadba59bb26d67be2f8b7;hp=5a691b92b669f48751da85d1e343babd76afd480;hb=0475fa677a3cda7c420351748925cb5149f73376;hpb=2c9ea76af28d3d5a506676380ff2890e8b6fd8d3 diff --git a/nmea.c b/nmea.c index 5a691b9..4d9cb90 100644 --- a/nmea.c +++ b/nmea.c @@ -30,6 +30,7 @@ #include #include #include +#include #include #include @@ -314,7 +315,7 @@ nmea_open(char *dev, struct ustream_fd *s, speed_t speed) tty = open(dev, O_RDWR | O_NOCTTY | O_NONBLOCK); if (tty < 0) { - ERROR("%s: device open failed\n", dev); + ERROR("%s: device open failed: %s\n", dev, strerror(errno)); return -1; }