summaryrefslogtreecommitdiff
path: root/hex.c
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2016-03-29 15:28:44 -0700
committerGary E. Miller <gem@rellim.com>2016-03-29 16:29:13 -0700
commitab6cc0be8748d025ed571fc70e9f9bf30aecd443 (patch)
tree41ba81e5cce48d175b9d19cffa461f9b9c88016b /hex.c
parentb6cdab96a905685d9c7f81433cd4a0506ff5b529 (diff)
downloadgpsd-ab6cc0be8748d025ed571fc70e9f9bf30aecd443.tar.gz
Comment what gpsd_packetdump() does
Diffstat (limited to 'hex.c')
-rw-r--r--hex.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/hex.c b/hex.c
index 606356af..0326971c 100644
--- a/hex.c
+++ b/hex.c
@@ -8,6 +8,18 @@
#include "gpsd.h"
+/*
+ * gpsd_packetdump()
+ *
+ * if binbuf is printable, just return a copy of it
+ * otherwise) convert a binary string to a hex string and return that
+ *
+ * *scbuf -- the buffer to fill with hex
+ * scbuflen -- sizeof(scbuf)
+ * *binbuf -- the binary to convert to hex and place in scbuf
+ * binbuflen -- sizeof(binbuf)
+ */
+
const char *gpsd_packetdump(char *scbuf, size_t scbuflen,
char *binbuf, size_t binbuflen)
{