ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/AnyEvent-HTTP/HTTP.pm
(Generate patch)

Comparing AnyEvent-HTTP/HTTP.pm (file contents):
Revision 1.119 by root, Sun Jun 8 23:33:28 2014 UTC vs.
Revision 1.120 by root, Sun Jun 8 23:36:36 2014 UTC

46use AnyEvent::Util (); 46use AnyEvent::Util ();
47use AnyEvent::Handle (); 47use AnyEvent::Handle ();
48 48
49use base Exporter::; 49use base Exporter::;
50 50
51our $VERSION = 2.2; 51our $VERSION = 2.21;
52 52
53our @EXPORT = qw(http_get http_post http_head http_request); 53our @EXPORT = qw(http_get http_post http_head http_request);
54 54
55our $USERAGENT = "Mozilla/5.0 (compatible; U; AnyEvent-HTTP/$VERSION; +http://software.schmorp.de/pkg/AnyEvent)"; 55our $USERAGENT = "Mozilla/5.0 (compatible; U; AnyEvent-HTTP/$VERSION; +http://software.schmorp.de/pkg/AnyEvent)";
56our $MAX_RECURSE = 10; 56our $MAX_RECURSE = 10;
846 # send request 846 # send request
847 $hdl->push_write ( 847 $hdl->push_write (
848 "$method $rpath HTTP/1.1\015\012" 848 "$method $rpath HTTP/1.1\015\012"
849 . (join "", map "\u$_: $hdr{$_}\015\012", grep defined $hdr{$_}, keys %hdr) 849 . (join "", map "\u$_: $hdr{$_}\015\012", grep defined $hdr{$_}, keys %hdr)
850 . "\015\012" 850 . "\015\012"
851 . (delete $arg{body}) 851 . $arg{body}
852 ); 852 );
853 853
854 # return if error occurred during push_write() 854 # return if error occurred during push_write()
855 return unless %state; 855 return unless %state;
856 856

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines