summaryrefslogtreecommitdiff
path: root/json.c
diff options
context:
space:
mode:
authorFred Wright <fw@fwright.net>2016-12-24 17:00:20 -0800
committerFred Wright <fw@fwright.net>2016-12-25 12:53:04 -0800
commitadcba9ae23b8bce85cf7f3f25e6b30113d7a1e5a (patch)
tree483de8d842a87ae21f0bafb0cc6ff9d7d68284ea /json.c
parent04ac607bcf742785f08feef5e3f8ce4a85858a05 (diff)
downloadgpsd-adcba9ae23b8bce85cf7f3f25e6b30113d7a1e5a.tar.gz
Changes fake.py stream type to 'bytes'.
Given that the data returned bye fake.py may include binary data, 'bytes' is a more appropriate type. Unlike the client API, where it's easy to provide both return types, it would be less convenient to do that here, so 'bytes' is preferred as the one choice (and is consistent with network sockets). When sending such data to stdout (or stderr), the straightforward method is to write to sys.stdXXX.buffer rather than sys.stdXXX. That doesn't exist in Python 2, but a helper function is now provided to get the appropriate 'bytes' stream for stdXXX. Since no previous *release* of GPSD is compatible with Python 3, changing this now doesn't break anything based on released code. TESTED: Ran "scons check" on OSX with all supported Python versions.
Diffstat (limited to 'json.c')
0 files changed, 0 insertions, 0 deletions