[MINOR] log: ability to override the syslog tag

One of the requirements we have is to run multiple instances of haproxy on a
single host; this is so that we can split the responsibilities (and change
permissions) between product teams. An issue we ran up against is how we
would distinguish between the logs generated by each instance. The solution
we came up with (please let me know if there is a better way) is to override
the application tag written to syslog. We can then configure syslog to write
these to different files.

I have attached a patch adding a global option 'log-tag' to override the
default syslog tag 'haproxy' (actually defaults to argv[0]).
diff --git a/src/haproxy.c b/src/haproxy.c
index 9ba0820..78e1029 100644
--- a/src/haproxy.c
+++ b/src/haproxy.c
@@ -94,7 +94,6 @@
 
 /* list of config files */
 static struct list cfg_cfgfiles = LIST_HEAD_INIT(cfg_cfgfiles);
-char *progname = NULL;		/* program name */
 int  pid;			/* current process id */
 int  relative_pid = 1;		/* process id starting at 1 */
 
@@ -352,6 +351,7 @@
 	char *cfg_pidfile = NULL;
 	int err_code = 0;
 	struct wordlist *wl;
+	char *progname;
 
 	/* NB: POSIX does not make it mandatory for gethostname() to NULL-terminate
 	 * the string in case of truncation, and at least FreeBSD appears not to do
@@ -405,6 +405,9 @@
 	while ((tmp = strchr(progname, '/')) != NULL)
 		progname = tmp + 1;
 
+	/* the process name is used for the logs only */
+	global.log_tag = strdup(progname);
+
 	argc--; argv++;
 	while (argc > 0) {
 		char *flag;
@@ -868,6 +871,7 @@
 	protocol_unbind_all();
 
 	free(global.log_send_hostname); global.log_send_hostname = NULL;
+	free(global.log_tag); global.log_tag = NULL;
 	free(global.chroot);  global.chroot = NULL;
 	free(global.pidfile); global.pidfile = NULL;
 	free(global.node);    global.node = NULL;