]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
CLEANUP: server: add "const" to some message strings
authorThierry Fournier <tfournier@arpalert.org>
Wed, 24 Feb 2016 07:23:22 +0000 (08:23 +0100)
committerWilly Tarreau <w@1wt.eu>
Wed, 24 Feb 2016 22:37:39 +0000 (23:37 +0100)
"updater" is used in "read only" mode, so I add a const qualifier
to the variable declaration.

include/proto/server.h
src/server.c

index d75cc9f0838975bf9b714b538fbcb103993200e8..99af0d4528f91b15cbd69031d1d91c0ff165625a 100644 (file)
@@ -39,7 +39,7 @@ int srv_downtime(const struct server *s);
 int srv_lastsession(const struct server *s);
 int srv_getinter(const struct check *check);
 int parse_server(const char *file, int linenum, char **args, struct proxy *curproxy, struct proxy *defproxy);
-int update_server_addr(struct server *s, void *ip, int ip_sin_family, char *updater);
+int update_server_addr(struct server *s, void *ip, int ip_sin_family, const char *updater);
 struct server *server_find_by_id(struct proxy *bk, int id);
 struct server *server_find_by_name(struct proxy *bk, const char *name);
 struct server *server_find_best_match(struct proxy *bk, char *name, int id, int *diff);
index cd32e8040c9137f681a25478c0f990053b40c810..4e8f835dc5cdae462665e26a6c95e7d059b40e98 100644 (file)
@@ -2558,7 +2558,7 @@ fileclose:
  *
  * A log line and a stderr warning message is generated based on server's backend options.
  */
-int update_server_addr(struct server *s, void *ip, int ip_sin_family, char *updater)
+int update_server_addr(struct server *s, void *ip, int ip_sin_family, const char *updater)
 {
        /* generates a log line and a warning on stderr */
        if (1) {