summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaweł Redman <pawel.redman@gmail.com>2017-04-06 22:50:42 +0200
committerPaweł Redman <pawel.redman@gmail.com>2017-04-06 22:50:42 +0200
commita26bcb4fc45b4055136216e2425cd39f8fb38f3f (patch)
treead71b29e913f2e1bcf1a60dc6935cac26f86c3b4
parent61f2d0e71b7df4ee6fdd1747c6149541d0411044 (diff)
Change the protocol to work with Q3.
-rw-r--r--src/main.c2
-rw-r--r--src/shared.h4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/main.c b/src/main.c
index 44d831d..f69f4e3 100644
--- a/src/main.c
+++ b/src/main.c
@@ -180,7 +180,7 @@ static int parse_argv(int argc, char **argv)
case 'h':
puts("usage: " PROGRAM_NAME " [-h] [-v] [-p PORT] [-l LISTS-FILE]");
- exit();
+ exit(0);
case 'p':
config.port = atoi(optarg);
diff --git a/src/shared.h b/src/shared.h
index 46c900e..bf4adeb 100644
--- a/src/shared.h
+++ b/src/shared.h
@@ -42,9 +42,9 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
#define LOCALHOST_NETWORK 0x7F000000
#define LOCALHOST_MASK 0xFF000000
-#define REQUEST_HEADER "query "
+#define REQUEST_HEADER "\xFF\xFF\xFF\xFFsm2query "
#define REQUEST_HEADER_LEN (sizeof(REQUEST_HEADER) - 1)
-#define RESPONSE_HEADER "reply "
+#define RESPONSE_HEADER "\xFF\xFF\xFF\xFFsm2reply "
// main.c