summaryrefslogtreecommitdiff
path: root/gps
diff options
context:
space:
mode:
Diffstat (limited to 'gps')
-rw-r--r--gps/client.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/gps/client.py b/gps/client.py
index 8d9d858c..a1a5b68f 100644
--- a/gps/client.py
+++ b/gps/client.py
@@ -153,7 +153,9 @@ class gpscommon(object):
def send(self, commands):
"Ship commands to the daemon."
- lineend = polybytes("\n")
+ lineend = "\n"
+ if isinstance(commands, bytes):
+ lineend = polybytes("\n")
if not commands.endswith(lineend):
commands += lineend