MINOR: log: Add "sample" new keyword to "log" lines.

This patch implements the parsing of "sample" new optional keyword for "log" lines
to be able to sample and balance the load of log messages between serveral log
destinations declared by "log" lines. This keyword must be followed by a list of
comma seperated ranges of indexes numbered from 1 to define the samples to be used
to balance the load of logs to send. This "sample" keyword must be used on "log" lines
obviously before the remaining optional ones without keyword. The list of ranges
must be followed by a colon character to separate it from the log sampling size.

With such following configuration declarations:

   log stderr local0
   log 127.0.0.1:10001 sample 2-3,8-11:11 local0
   log 127.0.0.2:10002 sample 5:5 local0

in addition to being sent to stderr, about the second "log" line, every 11 logs
the logs #2 up to #3 would be sent to 127.0.0.1:10001, then #8 up tp #11 four
logs would be sent to the same log server and so on periodically. Logs would be
sent to 127.0.0.2:100002 every 5 logs.

It is also possible to define the size of the sample with a value different of
the maximum of the high limits of the ranges, for instance as follows:

   log 127.0.0.1:10001 sample 2-3,8-11:15 local0

as before the two logs #2 and #3 would be sent to 127.0.0.1:10001, then #8
up tp #11 logs, but in this case here, this would be done periodically every 15
messages.

Also note that the ranges must not overlap each others. This is to ease the
way the logs are periodically sent.
diff --git a/include/types/log.h b/include/types/log.h
index d4d5976..9f9912a 100644
--- a/include/types/log.h
+++ b/include/types/log.h
@@ -169,9 +169,33 @@
 #define LW_FRTIP 	8192	/* frontend IP */
 #define LW_XPRT		16384	/* transport layer information (eg: SSL) */
 
+/* Range of indexes for log sampling. */
+struct smp_log_range {
+	unsigned int low;        /* Low limit of the indexes of this range. */
+	unsigned int high;       /* High limit of the indexes of this range. */
+	size_t sz;               /* The size of this range, or number of indexes in
+	                          * this range.
+	                          */
+	unsigned int curr_idx;   /* The current index used to sample this range of
+	                          *indexes.
+	                          */
+};
+
+/* Log sampling information. */
+struct smp_info {
+	struct smp_log_range *smp_rgs; /* Array of ranges for log sampling. */
+	size_t smp_rgs_sz;             /* The size of <smp_rgs> array. */
+	size_t smp_sz;             /* The total number of logs to be sampled. */
+	unsigned int curr_rg;      /* The current range to be sampled. */
+	unsigned int curr_idx;     /* A counter to store the current index of the log
+	                            * already sampled.
+	                            */
+};
+
 struct logsrv {
 	struct list list;
 	struct sockaddr_storage addr;
+	struct smp_info lb;
 	int format;
 	int facility;
 	int level;