Commit Graph

2501 Commits

Author SHA1 Message Date
ajohnsen@google.com 919ece9a32 Add 'start' and 'end' optional arguments to File.openRead(). This makes it possible to stream a sub-range of a file.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//15547003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22922 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 09:22:24 +00:00
ajohnsen@google.com 7715b19218 Add timeouts to HttpClient.
This introduces a per-connection timeout, configurable by setting
HttpClient.idleTimeout.

This also introduces a per-HttpClient timeout that will close idle
connections, if there have been no active connections for 100 ms.

BUG=https://code.google.com/p/dart/issues/detail?id=4857
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//15268004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22920 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 09:01:20 +00:00
ajohnsen@google.com d605223c12 Fix socket leak in HttpServer, when the connection is closed while receiving data.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//15293002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22886 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-18 09:15:29 +00:00
ajohnsen@google.com df4f281732 Use dart:crypto's Base64 methods in dart:io.
BUG=https://code.google.com/p/dart/issues/detail?id=9927
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//15298004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22885 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-18 09:12:56 +00:00
hausner@google.com 18aaaef686 Always send kill signal to debug target
Make sure we kill the debug target process in all cases
to ensure that no zombie processes linger around.

Also make sure the cleanup code gets only called once.

Review URL: https://codereview.chromium.org//15295014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22866 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 18:37:28 +00:00
ajohnsen@google.com 1ef03d33a1 Rewrite parts of http-parser, to better handle connection errors and pausing.
We now correctly catch up and report 'dead' connections in the
HttpClient.

BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//15256002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22834 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 08:28:21 +00:00
ajohnsen@google.com 1e7a090f26 Actually end a ZLib stream with a Z_FINISH marker.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14962006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22830 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 06:28:30 +00:00
hausner@google.com 2b7746ae05 Allow breakpoints on one-liner functions
Fixes issue 10234. This is also the first step for setting
reliable breakpoints on a == b expressions.

R=srdjan@google.com

Review URL: https://codereview.chromium.org//15000005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22799 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 15:44:05 +00:00
ahe@google.com a8fa4385c0 Remove .dart suffix from status file
Review URL: https://codereview.chromium.org//14598022

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22793 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 14:17:34 +00:00
ahe@google.com 570e59f5e9 Update status file after dart:typed_data no longer causes mock compilation
R=johnniwinther@google.com

Review URL: https://codereview.chromium.org//14693005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22792 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 14:09:19 +00:00
ajohnsen@google.com fefb5b9739 Don't decodeHttpEntityString on urlencoded post data.
The browser defaults to http-entiti-encoding for characters it can't
handle, when served in default encoding (Latin1). Trying to decode these
will lead to unambiguity for utf8 posts.

BUG=https://code.google.com/p/dart/issues/detail?id=10687
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14834016

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22779 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 10:03:58 +00:00
kustermann@google.com 8597b143e3 Fixed syntax error in debug_lib.dart
R=ricow@google.com

Review URL: https://codereview.chromium.org//15119003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22778 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 08:28:47 +00:00
ajohnsen@google.com 3a7ca53eb5 Don't run url_encoding_test on dart2js.
BUG=

Review URL: https://codereview.chromium.org//14916011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22776 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 08:12:25 +00:00
kustermann@google.com f87e9a5ca5 Fixed debugger_test to wait until target process is dead
R=hausner@google.com

Review URL: https://codereview.chromium.org//14773038

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22775 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 08:06:41 +00:00
ajohnsen@google.com 8dca71e459 Add optional defaultEncoding to HttpBodyHandler, as a way to override default encoding for 'application/x-www-form-urlencoded'.
We should look into other places where defaultEncoding might make sense.

BUG=http://code.google.com/p/dart/issues/detail?id=10649
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//15221002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22772 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 07:44:18 +00:00
sgjesse@google.com efe04dbed3 Improve parsing of query string
R=ager@google.com

BUG=https://code.google.com/p/dart/issues/detail?id=10168
TEST=tests/standalone/io/url_encoding_test.dart

Review URL: https://codereview.chromium.org//14897006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22728 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 09:29:08 +00:00
sgjesse@google.com 909b19c61c Allow proxy settings in environment variables to be full URLs
We used to remove any http:// prefix, but did not do anything if there
was a path. Any path is now ignored.

R=ager@google.com

BUG=https://code.google.com/p/dart/issues/detail?id=10661
TEST=tests/standalone/io/http_proxy_configuration_test.dart

Review URL: https://codereview.chromium.org//15188003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22726 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 09:10:52 +00:00
ricow@google.com 0bae839404 Mark standalone/debugger/basic_debugger_test as flaky crashing
Reopened issue 10488

Review URL: https://codereview.chromium.org//14676016

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22721 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 05:44:00 +00:00
whesse@google.com 3b0fe0f118 Disable standalone/io/raw_server_socket_cancel_test.
It is marked as flaky, has a bug assigned, and times out always, causing
more work for the buildbots.

BUG=dartbug.com/8675
R=kustermann@google.com

Review URL: https://codereview.chromium.org//14856020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22687 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-14 16:34:23 +00:00
whesse@google.com fb8471244f dart:io | Add FileSystemEntity.stat() and FileStat class.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//15018011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22685 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-14 16:26:13 +00:00
srdjan@google.com d0c639e474 Fix for issue 10534. Implement int.pow correctly using exponentiation by squaring.
Note that int.pow is now considerably slower than double.pow.

R=floitsch@google.com

Review URL: https://codereview.chromium.org//14619027

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22635 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-13 17:41:58 +00:00
hausner@google.com d0eea20dfa Add a debugger test for closure breakpoints
Stop at closure, step into the closure function.

R=asiva@google.com

Review URL: https://codereview.chromium.org//14864024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22605 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-10 22:45:59 +00:00
asiva@google.com 30b5101fd1 Fix for issue 10488 standalone/basic_debugger_test flaky
R=hausner@google.com

Review URL: https://codereview.chromium.org//15051002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22531 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-08 21:27:54 +00:00
ajohnsen@google.com 0226ce951b Make sure we always unsubscribe from a stream, in http-impl.
Fixes http_server_early_client_close test.

BUG=https://code.google.com/p/dart/issues/detail?id=10408
R=floitsch@google.com

Review URL: https://codereview.chromium.org//14729013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22508 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-08 14:45:55 +00:00
ajohnsen@google.com 0e14088b83 Make web-socket pass AutobanhTestSuite.
BUG=http://code.google.com/p/dart/issues/detail?id=10506
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14696012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22502 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-08 12:40:23 +00:00
scheglov@google.com 2214a97df7 Update status files for 'dartanalyer'.
Small tweak for the Java command line analyzer to actually support --package-root option in batch.

R=devoncarew@google.com
BUG=

Review URL: https://codereview.chromium.org//14786020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22480 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 21:45:20 +00:00
ajohnsen@google.com 1ecec950a2 Implement support for application/x-www-form-urlencoded' form data in HttpBodyHandler.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14660009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22461 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 14:04:51 +00:00
sgjesse@google.com 81245e5b5c Add support for digest authentication of HTTP proxies
R=ajohnsen@google.com
BUG=

Review URL: https://codereview.chromium.org//14660011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22460 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 13:59:24 +00:00
ajohnsen@google.com ad94e46940 Extend HttpBody handler to support 'multipart/form-data'.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14865008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22457 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 11:56:52 +00:00
sgjesse@google.com bcfd8c27a2 Fix digest authentication to use the correct URI
R=whesse@google.com
BUG=

Review URL: https://codereview.chromium.org//14595008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22455 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 09:10:17 +00:00
ricow@google.com d7f6ff21d3 Mark io/http_server_early_client_close2_test as flaky
This is currently marked as Fail, but it is flaking:
http://build.chromium.org/p/client.dart/builders/vm-mac-debug/builds/9764/steps/tests/logs/stdio

There is already an issue for this ( http://dartbug.com/10408 )

R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14959010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22451 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 07:09:45 +00:00
ricow@google.com 176c77518b Mark standalone/debugger/basic_debugger_test as flaky crashing
Review URL: https://codereview.chromium.org//14842009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22449 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-07 06:07:20 +00:00
floitsch@google.com 59ae6f296d Mark early close test as flaky.
Review URL: https://codereview.chromium.org//14992004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22431 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-06 17:02:09 +00:00
floitsch@google.com 968ebcff5a Make Completers asynchronous.
BUG= http://dartbug.com/9990
R=ajohnsen@google.com, lrn@google.com

Review URL: https://codereview.chromium.org//14690009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22417 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-06 15:15:15 +00:00
ajohnsen@google.com 3828f0a0b9 Add new HttpMultipartFormData, used for parsing a MimeMultipart and extracting either text or binary data.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14796015

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22414 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-06 14:12:55 +00:00
ajohnsen@google.com dae8b14d02 Support redirect to relative Uri, as specified by rfc3986#4.2.
BUG=https://code.google.com/p/dart/issues/detail?id=10210
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14988003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22413 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-06 13:59:19 +00:00
sgjesse@google.com f13b6178e1 Change fromString constructor to parse static method
on HeaderValue and ContentType.

R=ajohnsen@google.com
BUG=

Review URL: https://codereview.chromium.org//14914002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22406 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-06 07:30:02 +00:00
sgjesse@google.com 73c8411981 Extend HTTP digest support with server changing nonce
Support the server changing nonce. Supportts Both a server sending a
new 401 response with stale=true in the WWW-Authenticate response
header and a server using nextnonce in the Authentication-Info
response header.

R=ajohnsen@google.com
BUG=

Review URL: https://codereview.chromium.org//14595006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22369 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-03 13:10:41 +00:00
whesse@google.com 28f3bc37e7 dart:io | Tiny change to Link.exists().
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14907009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22368 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-03 12:39:07 +00:00
whesse@google.com 0ae62a79dc dart:io | Implement truly asynchronous version of FileSystemEntity.type().
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14907002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22364 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-03 12:02:10 +00:00
ajohnsen@google.com 3cb1d3d098 Fix dartc status files, after mime_multipart_parser_test change.
BUG=

Review URL: https://codereview.chromium.org//14771012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22359 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-03 10:28:27 +00:00
ajohnsen@google.com 157fbba220 Update mime_multipart_parser to be a StreamTransformer, public available.
On top of this, we can put in more user-friendly version, including
header objects.

BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14905003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22358 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-03 09:31:03 +00:00
sgjesse@google.com a6bc37f118 Implementation of HTTP digest authentication
This is the initial implementation. I am still missing the handling of
the server changing the nonce, but will do that in a separate CL.

Also this is currently not for proxy authentication.

R=ajohnsen@google.com
BUG=

Review URL: https://codereview.chromium.org//14740015

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22356 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-03 08:58:39 +00:00
whesse@google.com 396011beae dart:io | Add asynchronous versions of the methods of FileSystemEntity and Link.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14642012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22354 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-03 08:39:16 +00:00
whesse@google.com 22c995e8d7 Skip a failing test that is leaving directories in /tmp.
BUG=
R=kustermann@google.com

Review URL: https://codereview.chromium.org//14636007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22317 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-02 12:16:51 +00:00
ajohnsen@google.com 70096aa982 Clear http session object on destroy.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14840009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22310 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-02 11:25:10 +00:00
ajohnsen@google.com 6a78c0c0b8 Add v6Only named argument to ServerSocket and etc.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//14766003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22309 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-02 11:23:40 +00:00
ajohnsen@google.com 954ba85c7a Always connect using HOST_NAME, but swicth on host source on secure upgrade, in secure_upgrade test.
BUG=

Review URL: https://codereview.chromium.org//14771007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22247 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-01 14:27:57 +00:00
ajohnsen@google.com d548955117 Enable parsing of IPv6 form addresse (see rfc2373 and rfc2732).
This also wraps the 'domain' component in toString with [...], if it
contains any ':' characters.

BUG=
R=floitsch@google.com, sgjesse@google.com

Review URL: https://codereview.chromium.org//14753005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22228 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-01 09:27:50 +00:00
sgjesse@google.com 2fdb878ebe Change the signature for all network bind calls.
All the bind calls on RawServerSocket, ServerSocket,
RawSecureServerSocket, SecureServerSocket and HttpServer (and
bindSecure on HttpServer) now have mandatory address and port
parameters. All the rest of the parameters are named optional
(including backlog).

The address parameter can be an InternetAddress or a String for all
these calls.

R=ajohnsen@google.com, whesse@google.com
BUG=

Review URL: https://codereview.chromium.org//14640008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22227 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-01 09:14:04 +00:00