summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2018-03-09 10:49:48 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2018-03-09 10:49:48 +0100
commitec0e368a7faf206c3cc1c9f8a1039abac655353a (patch)
treea038770555a273464b97b1c649104c6b8bc259b5
parent1275de1b07f8182d2a1b4008cc6cfd2b9c34117c (diff)
downloadvdr-ec0e368a7faf206c3cc1c9f8a1039abac655353a.tar.gz
vdr-ec0e368a7faf206c3cc1c9f8a1039abac655353a.tar.bz2
Handling SVDRP commands case insensitive
-rwxr-xr-xpeerdemo10
1 files changed, 5 insertions, 5 deletions
diff --git a/peerdemo b/peerdemo
index 8f2f70ff..7129207b 100755
--- a/peerdemo
+++ b/peerdemo
@@ -76,20 +76,20 @@ while (1) {
$fh->recv($Request, 1024);
chomp($Request);
Log('<', $fh, $Request) if ($Request);
- if ($Request =~ /^CONN/) {
+ if ($Request =~ /^CONN/i) {
Reply($fh, "250 OK");
ReportVDR($Request, $fh->peerhost());
}
- elsif ($Request =~ /^LSTT/) {
+ elsif ($Request =~ /^LSTT/i) {
Reply($fh, "550 No timers defined");
}
- elsif ($Request =~ /^POLL/) {
+ elsif ($Request =~ /^POLL/i) {
Reply($fh, "250 OK");
}
- elsif ($Request =~ /^PING/) {
+ elsif ($Request =~ /^PING/i) {
Reply($fh, "250 $Name is alive");
}
- elsif ($Request =~ /^QUIT/ || !$Request) {
+ elsif ($Request =~ /^QUIT/i || !$Request) {
# close connection:
Log('<', $fh, "connection closed");
$SvdrpSelect->remove($fh);