Author: sparky
Date: Sat Jun 26 22:29:06 2010
New Revision: 11595

Modified:
   toys/rsget.pl/Direct/HTTP
Log:
- added redirect detection, for arbitrary redirecting sites


Modified: toys/rsget.pl/Direct/HTTP
==============================================================================
--- toys/rsget.pl/Direct/HTTP   (original)
+++ toys/rsget.pl/Direct/HTTP   Sat Jun 26 22:29:06 2010
@@ -22,6 +22,9 @@
        my ( $len ) = /^Content-Length:\s*(\d+)\r?$/mi;
        $len ||= -1;
 
+       if ( /^Location:\s*\s+/mi ) {
+               LINK( $-{_referer} );
+       }
        ERROR( "file is text ($type)" ) if $type =~ m#^text/#;
        ERROR( "file is a small image ($type, $len)" )
                if $type =~ m#^image/# and $len < 100 * 1024;
_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to