summaryrefslogtreecommitdiff
path: root/gpspacket.c
Commit message (Collapse)AuthorAgeFilesLines
* LICENSE: Update licenses for consistency. No functional changes.Gary E. Miller2018-11-191-1/+1
|
* SPDXify the licerse references.Eric S. Raymond2018-03-081-1/+1
|
* Fix ref-leak of PyObject_Call.Kurt Schwehr2017-07-181-1/+2
| | | | | | | | | | | | | | Py_XDECREF is slightly safer than Py_DECREF (not NULL-safe). https://docs.python.org/3/extending/extending.html The return value is a brand new object, or it is an existing object whose reference count has been incremented. Signed-off-by: Fred Wright <fw@fwright.net> TESTED: Verified that gpscat still works. - fw
* for vsnprintf() FreeBSD wants __ISO_C_VISIBLE >= 1999Gary E. Miller2016-08-161-0/+4
| | | | | Sad, C99 did not actually standardize the defines to invoke the standard.
* Fixes Python C extensions for Python 3 compatibility.Fred Wright2016-04-091-18/+13
| | | | | | | | | | | | | | | | | | | | | | | | | These are necessary, but not sufficient, changes to make the C extensions work "polyglot". These are believed to be complete as far as the C code is concerned, and don't break Python 2 compatibility. This puts all the stuff that needs to differ between Python 2 and Python 3 into conditionally-defined macros in a new header file python_compatibility.h. The definitions assume Python 2.6 or later. In addition to the things requiring conditionals, the Lexer object was using the deprecated tp_getattr entry, with a function based on Py_FindMethod, which is gone in Python 3. However, the newer tp_getattro entry can be pointed directly to PyObject_GenericGetAttr, which works in Python 2 and 3. Packet data returned by the Lexer is now 'bytes' in Python 3, which is appropriate given that it may contain binary data. However, it means that packet data can't be passed directly to anything expecting a 'str'. In Python 2, the data is just a 'str' as usual. TESTED: Ran "scons build-all check" and xgps (using Python 2.7). Also ran the daemon and maidenhead-locator tests with Python 2.6.
* A gaggle of whitespace gaffs.Gary E. Miller2015-04-301-1/+1
|
* Use LOG_* symbol when setting/comparing log levelZbigniew Chyla2015-03-221-1/+1
| | | | | Currently, debug level 0 is actually LOG_SHOUT. This change doesn't affect generated binary code.
* gpsd-report() -> gpsd_log()Eric S. Raymond2015-03-071-2/+2
| | | | | | | | | | | | | | | | This change is done so we can add a "log" hook to the pps_thread_t structure (this is not done yet) and harmonize with the name of the outer logging function. If that name had been left as gpsd_report() there would have been scope for bad confusion with the report_hook member. Also, remove two stray duplicative printf calls from the NMEA2000 driver (drivers shouldn't have printfs!) and fix one typo. This is a step towards factoring out ntplib. For that to happen, the PPS thread code needs to be decoupled from the core session structure. No logic changes. Object compatibility preserved. All regression tests pass.
* Make PACKET_TYPES available in the Python interface.Eric S. Raymond2015-02-061-0/+1
|
* Now that the transition is done we can restore the gpsd_report name.Eric S. Raymond2014-08-271-2/+2
| | | | All regression tests pass.
* Reverse linkage of gpsd_report() is abolished. All regression tests pass.Eric S. Raymond2014-08-271-26/+0
| | | | Some cleanup and testing is still required.
* Introduce struct errout_t to encapsulate error-reporting hooks.Eric S. Raymond2014-08-271-0/+39
| | | | | | A major step towards eliminating reverse linkage. All regression tests pass.
* Structure member name change: packet -> lexer. No logic changes.Eric S. Raymond2014-08-271-2/+2
| | | | All regression tests pass.
* Restore some Python constants needed for gpscat to work.Eric S. Raymond2013-11-281-0/+11
|
* Introduce new LOG_CLIENT looging level.Eric S. Raymond2013-11-161-2/+0
|
* Code is fully cppcheck, splint, and Coverity clean.Eric S. Raymond2013-11-061-0/+2
| | | | All regression tests pass. PPS is live.
* Change gpsd_report to no longer use a global. All regression tests pass.Eric S. Raymond2013-09-291-1/+1
| | | | | | | | This is a large, ugly change. But without it we can't troubleshoot the ICP/IP-source initialization bug properly - colliding definitions of gpsd_report() were interfering with error reporting early in gpsd runs. More cleanup work remains to be done, but at least this is working.
* Nuke trailing whitespace in C source.Eric S. Raymond2012-09-071-4/+4
|
* Elimination of gpsd_hexdump_level.Eric S. Raymond2011-06-171-2/+0
| | | | The few gpsd_hexdump() calls left have explicit guards.
* Typo fix.Eric S. Raymond2011-06-141-1/+1
|
* Add some missing packet types to the JSON interface.Eric S. Raymond2011-06-141-2/+6
|
* Banish some pointless compiler warnings.Eric S. Raymond2011-04-171-3/+6
|
* Have the Python packet-module interface export the character counter.Eric S. Raymond2011-03-011-2/+3
|
* Vanish away Id and Rev $ keywords, git won't expand them to anything useful.Eric S. Raymond2010-03-131-2/+2
|
* Copyright stamps everywhere. No code changes.Eric S. Raymond2010-03-111-2/+5
|
* Put Python extension modules under "gps.".Eric S. Raymond2009-12-151-5/+5
| | | | | | | | | The two Python extension modules used for our distribution test clients, gpslib and gpspacket, are now parts of an importable gps package. This change is needed so xgps2 (which is about to replace xgps) can depend only on being able to do "import gps". All regression tests pass.
* Include the whole config file in gpsd.h.Eric S. Raymond2009-11-201-1/+0
| | | | | | | That is, instead of sectioning out two little config defines and putting them in. This makes gpsd.h self-copntained (e.g. in case it gets installed as a library header) and means we can get rid of most inclusions of it.
* Significant simplification of the packet-getter interface. Eric S. Raymond2009-03-271-11/+3
| | | | | | | | packet_get() now always returns nonzero when it could either read fresh data or assemble a packet from data already read and buffered -- no more returning 0 when it has assembled a packet from buffered data but can't read any new data. I suspect this may have been causing subtle bugs.
* Fix buggy termination test,Eric S. Raymond2009-01-131-2/+4
|
* Improve the packet instrumentation slightly.Eric S. Raymond2009-01-121-0/+4
|
* Update the list of packet type defines. Plain RTCM_PACKET is gone.Eric S. Raymond2009-01-071-1/+6
|
* Revert previous EOF_PACKET change, it was a bad idea.Eric S. Raymond2008-07-141-2/+2
|
* Packet state machine now recognizes RTCM3 packets correctly.Eric S. Raymond2008-07-131-1/+2
| | | | | | Update the packet regression test load. Introduce new EOF_PACKET type to signal that the packet getter sees EOF. All regression tests pass.
* Fix gpscat to dump binary packets correctly. Eric S. Raymond2008-07-121-1/+5
| | | | Reenable some debugging in the packet getter, and add a bit more.
* Add verbosity option to gpscat.Eric S. Raymond2008-07-121-1/+1
|
* More namespace shuffles preparing for RTCM3.Eric S. Raymond2008-06-271-1/+1
|
* Name change.Eric S. Raymond2006-12-071-46/+44
|
* Give gpspacket.c a real doc string.Eric S. Raymond2006-12-071-2/+18
|
* This version works of gpspacket.c works and allows us to set a callback.Eric S. Raymond2006-12-071-16/+5
|
* Another patch from Andreas.Eric S. Raymond2006-12-071-5/+71
|
* Followed some advice from Andreas Stricker.Eric S. Raymond2006-12-061-15/+1
|
* Patch suggested by Andreas Stricker.Eric S. Raymond2006-12-061-3/+10
|
* Another step toward a Python wrapper for packet.c.Eric S. Raymond2006-12-051-1/+3
| | | | | gpscat now has an option that tried to invoke it. All regression tests pass.
* Add $Id$ tagChris Kuethe2006-12-051-0/+1
|
* First cut at a Python binding for the packet.c module.Eric S. Raymond2006-12-041-0/+195
It builds and imports without errors, but has not been tested yet.