SVN: toys/rsget.pl/RSGet/HTTPRequest.pm
sparky
sparky at pld-linux.org
Mon Jun 28 01:24:42 CEST 2010
Author: sparky
Date: Mon Jun 28 01:24:41 2010
New Revision: 11611
Modified:
toys/rsget.pl/RSGet/HTTPRequest.pm
Log:
- /captcha lists needed captchas if no post/get options have been passed
Modified: toys/rsget.pl/RSGet/HTTPRequest.pm
==============================================================================
--- toys/rsget.pl/RSGet/HTTPRequest.pm (original)
+++ toys/rsget.pl/RSGet/HTTPRequest.pm Mon Jun 28 01:24:41 2010
@@ -690,7 +690,7 @@
my $ct;
my $data;
- my $md5 = $post->{md5};
+ my $md5 = $post->{md5} || "";
if ( $post->{solve} ) {
delete $RSGet::Captcha::needed{ $md5 };
$RSGet::Captcha::solved{ $md5 } = $post->{solve};
@@ -700,11 +700,8 @@
( $ct, my $dataref ) = @$n;
$data = $$dataref;
} else {
- $ct = "image/png";
- local $/ = undef;
- open F_IN, '<', data_file( "error.png" );
- $data = <F_IN>;
- close F_IN;
+ $headers->{Content_Type} = "text/plain";
+ return join "\n", keys %RSGet::Captcha::needed, '';
}
$headers->{Content_Type} = $ct;
More information about the pld-cvs-commit
mailing list