On Sun, 2017-11-19 at 17:40 +0100, Peter Müller wrote: > Add option to change remote syslog protocol to TCP, which > is more reliable than UDP, but might be unsupported on > older syslog servers. > > Signed-off-by: Peter Müller > --- > html/cgi-bin/logs.cgi/config.dat | 16 ++++++++++++++ > 1 file changed, 16 insertions(+) > > diff --git a/html/cgi-bin/logs.cgi/config.dat b/html/cgi- > bin/logs.cgi/config.dat > index 789341dbe..ec3c2a92d 100644 > --- a/html/cgi-bin/logs.cgi/config.dat > +++ b/html/cgi-bin/logs.cgi/config.dat > @@ -33,6 +33,7 @@ $logsettings{'LOGWATCH_KEEP'} = '56'; > my @VS = ('15','50','100','150','250','500'); > $logsettings{'ENABLE_REMOTELOG'} = 'off'; > $logsettings{'REMOTELOG_ADDR'} = ''; > +$logsettings{'REMOTELOG_PROTOCOL'} = 'udp'; > $logsettings{'ACTION'} = ''; > &Header::getcgihash(\%logsettings); > > @@ -45,6 +46,10 @@ if ($logsettings{'ACTION'} eq $Lang::tr{'save'}) > { > $errormessage = $Lang::tr{'invalid logserver address'}; > } > + unless ($logsettings{'REMOTELOG_PROTOCOL'} =~ /^udp|tcp$/) > + { > + > + } So what was going to happen here? > } > unless ($logsettings{'LOGWATCH_KEEP'} =~ /^\d+$/) > { > @@ -69,6 +74,10 @@ $checked{'ENABLE_REMOTELOG'}{'off'} = ''; > $checked{'ENABLE_REMOTELOG'}{'on'} = ''; > $checked{'ENABLE_REMOTELOG'}{$logsettings{'ENABLE_REMOTELOG'}} = > "checked='checked'"; > > +$selected{'REMOTELOG_PROTOCOL'}{'udp'} = ''; > +$selected{'REMOTELOG_PROTOCOL'}{'tcp'} == ''; > +$selected{'REMOTELOG_PROTOCOL'}{$logsettings{'REMOTELOG_PROTOCOL'}} = > "selected='selected'"; > + > $checked{'LOGVIEW_REVERSE'}{'off'} = ''; > $checked{'LOGVIEW_REVERSE'}{'on'} = ''; > $checked{'LOGVIEW_REVERSE'}{$logsettings{'LOGVIEW_REVERSE'}} = > "checked='checked'"; > @@ -139,6 +148,11 @@ print < > $Lang::tr{'enabled'} name='ENABLE_REMOTELOG' $checked{'ENABLE_REMOTELOG'}{'on'} /> > $Lang::tr{'log server address'} name='REMOTELOG_ADDR' value='$logsettings{'REMOTELOG_ADDR'}' /> > + $Lang::tr{'log server protocol'} > + > > > END