summaryrefslogtreecommitdiff
path: root/libgps_sock.c
Commit message (Collapse)AuthorAgeFilesLines
* Retire splint from our set of static analyzers.Eric S. Raymond2015-03-301-28/+5
| | | | | | | | | | | | | | | | | | | The proximate cause was that we've been seing emission of error messages that were randomly and disturbingly variable across different environments - notably Raspbian and Gentoo splint gave nontrivially different results than Ubuntu 14.10 splint. And this was *not* due to Ubuntu patches! A pristine splint built from the 3.1.2 tarball on Ubuntu didn't match the Raspbian and Gentoo results either. But this has been coming for a while. Easy access to more modern static analyzers such as coverity, scan-build and cppcheck has been decreasing the utility of splint, which is unmaintained and somewhat buggy and not easy to use. Only file not cleaned is ppsthread.c, because Gary has been working on it during this cleanup. All regression tests pass. PPS observed live on GR601-W.
* Document SHM and JSON timeout is in uSec. Fix SHM so that is true.Gary E. Miller2015-03-121-0/+1
| | | | | JSON wait was in uSec, but SHM wait was in Sec. Made both uSec and documented three places.
* Since Windows should have full POSIX now, remove WIN32 port cruft.Eric S. Raymond2015-03-091-4/+0
| | | | It wasn't being used, anyway. There's no Windows port yet.
* Feature removal - delete last remnants of old pre-JSON protocol from libgps.Eric S. Raymond2015-02-221-262/+43
| | | | | All regression tests pass. Clients are working live. PPS observed on Macx-1.
* Easy splint cleanups. All regression tests pass.Eric S. Raymond2015-01-211-6/+6
|
* Add str_rstrip_char, use it everywhere.Zbigniew Chyla2015-01-211-4/+2
| | | | This change doesn't affect generated binary code.
* Add str_{,v}appendf, use it everywhere.Zbigniew Chyla2015-01-211-2/+1
| | | | This change doesn't affect generated binary code.
* Add str_starts_with macro, use it instead of strncmp.Zbigniew Chyla2015-01-211-1/+2
| | | | This change doesn't affect generated binary code.
* Fix a namespace-pollution issue that causes OS X build failures.Eric S. Raymond2015-01-091-0/+4
| | | | All regression tests pass.
* Refactor representation of satellite data into an array of structs...Eric S. Raymond2014-09-221-9/+6
| | | | | | | | | | | | | | | | | | ...from a set of parallel arrays. This change flushed out a longstanding bug in the computation of DOPs for estimated error bars. Some test-load rebuilds were required: geostar-geos1m-binary.log.chk: With this change error estimates are computed and reported. trimble-lassen_iq-3dfix.log, trimble-lassen_iq-3dfix.log: the change revealed a bug in the computation of satellite-seen bits. Error estimates did not change. navcom.log: Error estimates changed. With these rebuilds, all regression tests pass.
* Exit from gps_sock_mainloop() if connection to gpsd is lostDaniel Willmann2014-08-281-2/+6
| | | | | | | | | | | The current mainloop function does not evaluate the return value of gps_read(). If the socket is closed (because gpsd is stopped) the mainloop will consume 99% CPU constantly doing a recv() from the socket which returns zero. gps_read already returns -1 if this condition is encountered. This patch checks the return value of gps_read() and if it is -1 the mainloop is exited. This is also what happens in gps_shm_mainloop().
* Drop the obsolete tag field from JSON output. Bump the minor protocol number.Eric S. Raymond2014-08-241-9/+6
| | | | | | | Required a regression-test rebuild, of course. The field is still set by the TSIP and SiRF drivers; the SiRF driver actually uses it. It may be possible to eliminate the TSIP uses, but so far attempting this has produced odd regression-test failures.
* Include <sys/select.h> everywhere fd_set us used.Eric S. Raymond2014-08-181-0/+1
| | | | | | | | This came up in connection with Android. According to SuS this shouln't be necessary if sys/time.h was included, but oh well. While we;re at it, rearrange some includes for more consistent order. All regression tests pass.
* ppsbar -> pps.Eric S. Raymond2013-11-131-4/+4
| | | | All regression tests pass. PPS is live in both gpsd and gpsmon.
* Teach the client library about ppsbar...Eric S. Raymond2013-11-101-0/+4
| | | | | ...against the extremmely unlikely evebtuality of anything but gpsmon wanting to use it.
* Code is fully cppcheck, splint, and Coverity clean.Eric S. Raymond2013-11-061-0/+1
| | | | All regression tests pass. PPS is live.
* More cppcheck cleanup. All regression tests pass. PPS is live.Eric S. Raymond2013-11-061-1/+1
|
* Full splint cleanup. Partial cppcheck cleanup.Eric S. Raymond2013-11-051-1/+1
|
* Split Type 24 reporting, including the -s option to gpsdecode.Eric S. Raymond2013-09-141-0/+4
| | | | All regression tests pass.
* Nuke trailing whitespace in C source.Eric S. Raymond2012-09-071-2/+2
|
* More cppcheck warning fixups. All regression tests pass.Eric S. Raymond2012-05-181-0/+3
|
* Simplify code for parsing old protocol.Eric S. Raymond2012-05-101-22/+9
| | | | And prevent it from raising spurious Coverity warnings.
* The shm export gets a waiting method.Eric S. Raymond2011-10-031-1/+0
|
* Remove duplicate code.Michael Tatarinov2011-09-301-1/+0
| | | | Signed-off-by: Eric S. Raymond <esr@thyrsus.com>
* splint cleanup.Eric S. Raymond2011-09-301-0/+2
|
* Re-do runtime dispatch in the client library.Eric S. Raymond2011-09-301-4/+0
|
* splint cleanup.Eric S. Raymond2011-09-281-0/+2
|
* Avoid a name collision.Eric S. Raymond2011-09-281-2/+2
|
* First step in runtime export dispatch for the client library.Eric S. Raymond2011-09-281-0/+2
|
* splint cleanup.Eric S. Raymond2011-09-281-2/+2
|
* Break out prototypes for client library export methgods into a new heasder.Eric S. Raymond2011-09-281-0/+1
| | | | All regression tests pass. All three exports work in gpxlogger.
* Get back to a state where the shm export works.Eric S. Raymond2011-09-271-6/+6
|
* More API convergence.Eric S. Raymond2011-09-271-3/+1
|
* Converge the library APIs for different transports more closely.Eric S. Raymond2011-09-271-5/+7
|
* More refactoring.Eric S. Raymond2011-09-271-0/+16
| | | | | gpxlogger currently works with socket and DBUS methods but fails with a segfault in the shm code.
* Uniform use of safe_atof(). All regression tests pass.Eric S. Raymond2011-08-271-1/+5
|
* Make the sock_export=no build.Eric S. Raymond2011-08-261-13/+7
| | | | | | | | | | The way I fixed this extends the library API so some functions which were previously undefined for shm transport are now defined. This doesn't change the binary API of the library in the normal (sock_export=yes) case at all, so I'm not bumping its version. No changes in the daemon. All regression tests pass (in the normal sock_export=yes build).
* Add const qualifiers to some arguments never modified.Eric S. Raymond2011-04-061-2/+2
|
* trying to get compiling with socket-exportJon Schlueter2011-04-021-0/+1
|
* Magic-number and strncpy elimination. All regression tests passEric S. Raymond2011-03-291-2/+2
|
* Scan-build and splint cleanup. All regression tests pass.Eric S. Raymond2011-03-281-2/+2
|
* Shared-memory export is now integrated and documented.Eric S. Raymond2011-03-271-11/+18
|
* Begin splitting apart libgps_core.c into socket-export and generic functions.Eric S. Raymond2011-03-271-0/+564