Subject: | [PATCH] lwp-request (POST): relaxed content-type check |
Date: | Sun, 8 Apr 2007 00:29:29 +0400 |
To: | bug-libwww-perl [...] rt.cpan.org |
From: | Alexey Tourbin <at [...] altlinux.ru> |
text/vnd.wap.wml and application/vnd.oasis.opendocument.text
are prefectly valid values for content-type field.
Reported by Michael Bochkaryov
https://bugzilla.altlinux.org/show_bug.cgi?id=6792
---
bin/lwp-request | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/bin/lwp-request b/bin/lwp-request
index 147fbf3..49c155a 100755
--- a/bin/lwp-request
+++ b/bin/lwp-request
@@ -366,7 +366,7 @@ if ($allowed_methods{$method} eq "C") {
}
else {
die "$progname: Illegal Content-type format\n"
- unless $options{'c'} =~ m,^[\w\-]+/[\w\-]+(?:\s*;.*)?$,
+ unless $options{'c'} =~ m,^[\w\-]+/[\w\-.+]+(?:\s*;.*)?$,
}
print "Please enter content ($options{'c'}) to be ${method}ed:\n"
if -t;
--
1.5.1.GIT