]> git.meshlink.io Git - meshlink/blobdiff - src/protocol_key.c
Always pass request strings to other functions as const char *.
[meshlink] / src / protocol_key.c
index c62c04814412774d60a8182ff03dda5b4fd3e064..12dab09b02e9164f14d3c74f1cd50de9368a264c 100644 (file)
@@ -1,7 +1,7 @@
 /*
     protocol_key.c -- handle the meta-protocol, key exchange
     Copyright (C) 1999-2005 Ivo Timmermans,
-                  2000-2011 Guus Sliepen <guus@tinc-vpn.org>
+                  2000-2012 Guus Sliepen <guus@tinc-vpn.org>
 
     This program is free software; you can redistribute it and/or modify
     it under the terms of the GNU General Public License as published by
@@ -51,7 +51,7 @@ void send_key_changed(void) {
        }
 }
 
-bool key_changed_h(connection_t *c, char *request) {
+bool key_changed_h(connection_t *c, const char *request) {
        char name[MAX_STRING_SIZE];
        node_t *n;
 
@@ -87,7 +87,7 @@ bool send_req_key(node_t *to) {
        return send_request(to->nexthop->connection, "%d %s %s %d", REQ_KEY, myself->name, to->name, experimental ? 1 : 0);
 }
 
-bool req_key_h(connection_t *c, char *request) {
+bool req_key_h(connection_t *c, const char *request) {
        char from_name[MAX_STRING_SIZE];
        char to_name[MAX_STRING_SIZE];
        node_t *from, *to;
@@ -202,7 +202,7 @@ bool send_ans_key(node_t *to) {
                                                to->incompression);
 }
 
-bool ans_key_h(connection_t *c, char *request) {
+bool ans_key_h(connection_t *c, const char *request) {
        char from_name[MAX_STRING_SIZE];
        char to_name[MAX_STRING_SIZE];
        char key[MAX_STRING_SIZE];