| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
BUG=http://crbug.com/14478
Review URL: http://codereview.chromium.org/172100
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25227 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
destroyed.
This functionality will be used by the "about:net-internal" page to display profiling information for the in-progress requests, as well as the recently completed requests.
This does not have any performance impact. Note that all of the tracking operations are constant time.
In particular:
* Global tracking of all URLRequest instances is done by chaining them as
linked list nodes. So we get constant-time insertion/deletion without
needing to do any extra heap allocs.
* The recent requests list is a circular queue, backed by an array. So
insertions are constant time (and we never erase entries, just overwrite).
Moreover, the entry types themselves are comprised of {GURL, LoadLog*},
so very little copying actually happens -- LoadLog is refcounted so
copy is cheap, and GURL is backed by a std::string which is also refcounted
so the copy is cheap.
R=darin
BUG=http://crbug.com/14478
TEST=unittests.
Review URL: http://codereview.chromium.org/173175
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25158 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This page contains low-level debug information that is of interest to power users, and bug investigators.
The output can be filtered by using special sub-URLs.
The sub-URLs themselves are listed when visiting about:net-internal, but to give an idea:
about:net-internal -- everything
about:net-internal/proxyservice -- all things proxy
about:net-internal/proxyservice.config -- current settings
about:net-internal/hostresolver.hostcache -- dns cache
BUG=http://crbug.com/14478
R=darin
Review URL: http://codereview.chromium.org/173024
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25109 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
This should make licensing terms and third-party origin of the code more clear.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/179041
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25047 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I managed to save 30s with this change!
I had to change the interface of the test server a bit. Now the credentials
to be used are passed (optionally) for TestPage request, not in the ctor.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/182031
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24942 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
process ID with an internally-generated id() function. This allows us the
guarantee that the IDs are unique over the entire run of the application.
This also cleans up some code associated with managing the PID.
The main potentially interesting change is now the PID is set uniquely for
every creation of RenderProcessHost. It used to be set cleared if the process
went away, and re-set if the process was re-created. The ID generation is in
ChildProcesInfo so it is also unique between workers and plugins. I had to
change some significant things in resource_dispatcher_host_unittest to take
into account this new generation of IDs.
BUG=17828
TEST=none
Review URL: http://codereview.chromium.org/160203
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24899 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
request.TEST=Run automation unit tests.BUG=none
Review URL: http://codereview.chromium.org/183004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24888 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
a comma-separated list of ports.
BUG= http://crbug.com/18307
TEST= url_request_unittest, use commandline flag allowed_ports=1,600. Navigate to http://www.google.com:1 or http://www.google.com:600. You should not get an ERR_UNSAFE_PORT, it will attempt to load the page.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24883 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
This should help with decision which FTP server types we can safely stop supporting.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/176020
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24824 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit r24792.
TBR=estade
Review URL: http://codereview.chromium.org/179028
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24796 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Most of these are classes with virtual methods lacking virtual destructors
or NULL used in non-pointer context.
BUG=none
TEST=app_unittests && base_unittests
--gtest_filter=-ConditionVariableTest.LargeFastTaskTest
patch by Jacob Mandelson <jlmjlm [at] gmail>
http://codereview.chromium.org/171028/show
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24792 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
InterceptRestartRequired fail.
The unit tests still fail, but don't crash which allows the other tests to run.
TEST=Run UrlRequest unit tests.
BUG=none
Review URL: http://codereview.chromium.org/173572
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24610 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
TEST=Covered by net_unittests.
http://crbug.com/20112
Review URL: http://codereview.chromium.org/173270
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24449 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Added unit tests for the above functionality plus the do not save cookies functionality.
BUG=http://crbug.com/10961
TEST=Added unit tests for this. Also, this isn't yet called from the rest of the code.
Review URL: http://codereview.chromium.org/173206
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24412 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
BUG=None
TEST=run base_unittests.exe
Review URL: http://codereview.chromium.org/173181
Patch from Thiago Farina <thiago.farina@gmail.com>.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24208 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We redirect a file URL that corresponds to a directory when the file URL does
not end in a slash. We redirect to the same URL with a slash appended to
simplify other code, which can then rely on the presence of a trailing slash
for all file URLs that correspond to a directory.
It turns out that following the redirect could result in the job being used
after free. The code in URLRequestJob::FollowDeferredRedirect clears some
fields after calling FollowRedirect. For all other jobs this is not a problem
since the process of following a redirect causes the job to be killed, and
URLRequestJob::Kill takes a reference to the job. It turns out that
URLRequestFileDirJob was not calling URLRequestJob::Kill, and so this extra
reference was not being taken.
The fix is two-fold:
1- Make URLRequestFileDirJob call URLRequestJob::Kill just like the rest of
the jobs. This seems like a good idea for other reasons as well.
2- Make URLRequestJob::FollowDeferredRedirect not depend on itself being alive
after the FollowRedirect call. This just seems good for future cases where a
special URLRequestJob subclass might not call URLRequestJob::Kill for some
reason or another.
Finally, some minor changes were rqeuired to URLRequestFileDirJob to support
the call to Kill. See changes to OnListDone.
Writing a unit test for this was a bit tricky. It turns out that while the
URLRequestFileDirJob is waiting for the client to call FollowDeferredRedirect,
it is still traversing the directory. It does not pause the directory listing.
The crash could only happen if the directory listing completed before the
consumer called FollowDeferredRedirect because a reference to the job was taken
on behalf of the DirectoryLister. To test this condition, I made it possible
for a test to poll the URLRequestFileDirJob::list_completed_ flag. Once that
is set, I then have the test call FollowDeferredRedirect.
NOTE: When running within net_unittests, NetModule::SetResourceProvider has not
been called. So, I downgraded a NOTREACHED to a DLOG(WARNING). NOTREACHED was
a bit excessive since it is a condition that can be reached, and I don't see
any problem with allowing unit tests to function without a resource provider.
R=wtc
BUG=18686
TEST=URLRequestTest.FileDirRedirectNoCrash
Review URL: http://codereview.chromium.org/174076
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23944 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
| |
Makes SSLConfigService into a ref-counted interface, and makes Profile own an SSLConfigServiceFactory which is used to create the SSLConfigService and pass it through the URLRequestContext on down to where it is actually used.
R=eroman,wtc
BUG=11507,19290
Review URL: http://codereview.chromium.org/165003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23757 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
track down all callers, also removes the
deprecated function that uses std::wstring.
BUG=3078 (http://crbug.com/3078)
TEST=run base_unittests, installer_util_unittests, net_unittests, setup_unittests, and unit_tests.
Review URL: http://codereview.chromium.org/164537
Patch from Thiago Farina.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23631 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is necessary since ProxyService is getting shared between chrome's url request contexts (off the record, media), and the current way it is being shared could result in free memory read/writes during shutdown.
This is a step towards fixing http://crbug.com/15289.
BUG=http://crbug.com/15289
TEST=The existing tests should continue to pass following this refactor.
Review URL: http://codereview.chromium.org/165430
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23612 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
I gained at least 30s by doing that, and there is still room for improvement!
I'm doing changes step-by-step to make sure it won't break mysteriously.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/172057
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23574 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On POSIX it makes the server fork a separate process for each request for better
test isolation.
Starting with just few tests to limit impact of an eventual breakage. The results are promising.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/164522
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23481 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
| |
Review URL: http://codereview.chromium.org/164531
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23419 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
TEST=Covered by net_unittests.
http://crbug.com/19095
Review URL: http://codereview.chromium.org/164354
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23201 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
| |
and proyxservice.This dependency comes from the parent URLRequest, and is used as a container for per-request profiling data.This change is strictly a no-op refactor -- the parameter is unused, and LoadLog does nothing.BUG=http://crbug.com/14478TEST=none -- just needs to compile and pass existing tests.DESIGN=<http://docs.google.com/Doc?id=dfhcnb2v_21gbtrcpr3&hl=en>
Review URL: http://codereview.chromium.org/126303
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23127 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
survives the destruction of the IO thread.
This checking is done by introducing a new helper class to base called LeakTracker. Classes that you want to check for leaks just need to extend LeakTracker.
The reason I am picking on URLFetcher / URLRequest, is I believe we have a bug that is making an instance of URLFetcher to outlive the IO thread.
This causes various sorts of badness.
For example:
If URLFetcher survives the IO thread, then URLRequestContext remains referenced and therefore also survives IO thread. In turn HostResolverImpl survives the IO thread, so any outstanding resolve requests are NOT cancelled before the IO thread is decomissioned. So now, when the worker thread doing the DNS resolve finally finishes (assuming it finishes before the rogue URLRequest is destroyed), it post the result to a defunct message loop. KAB00m! (http://crbug.com/15513)
Moreover, I believe we hit this same problem sporadically in AutomationProxyTest.AutocompleteGetSetText -- the test is flaky on the buildbots, and I've seen DCHECKs which suggest it is related to this issue.
BUG=http://crbug.com/18372
Review URL: http://codereview.chromium.org/160447
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23084 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
Also, use NotifyDone in URLRequestNewFtpJob instead of NotifyStartError. This way is_pending in URLRequest is correctly reset to false.
TEST=Covered by net_unittests.
http://crbug.com/18036
Review URL: http://codereview.chromium.org/165142
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22752 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
excluding the broken ones.
The change of GURL -> const GURL& caused some nasty crash and the change got reverted.
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/164095
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22682 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
miletus):
Make the timeout in WaitToStart() of TestServerLauncher parametrized and expose this parameter to HTTPTestServer::CreateServer()
TBR=syf1984@gmail.com, tommi@chromium.org
Review URL: http://codereview.chromium.org/164090
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22667 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This caused an easily reproducible crash:
1. Start with a fresh profile
2. Navigate to google.com
3. Restart
4. Navigate to google.com
5. crash
The change from pass-by-value to pass-by-ref in
fav_icon_helper.* seems to be to blame, but I can't see it
right off.
TBR=phajdan.jr@chromium.org
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22595 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/159862
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22559 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
Re-enable tests which were intermittently failing before this fix and remove
debugging code used to track down the issue.
TEST=Covered by net_unittests.
http://crbug.com/18036
Review URL: http://codereview.chromium.org/160537
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22500 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
ftp://ftp.mozilla.org/pub/addons/
The problem is that data was spooling on network stack and
after 8K data TCP Window size becomes small and no more
data is received after 8K. The fix is to change the
ERROR_CLASS_INITIATED case in the ProcessResponseLIST
function to not go back to the STATE_CTRL_READ state.
In URLRequestNewFtpJob::ProcessFtpDir. construct the
std::string from buf->data() and its length so that
buf->data() doesn't need to be null-terminated.
Author: Ibrar Ahmed <ibrar.ahmad@gmail.com>
Original review: http://codereview.chromium.org/146137
R=wtc,phajdan.jr
BUG=http://crbug.com/4965
TEST=ftp://ftp.mozilla.org/pub/addons/
Review URL: http://codereview.chromium.org/159663
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22217 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
The root cause is a bug in the code. I'm working on a fix.
TEST=none
http://crbug.com/18036
Review URL: http://codereview.chromium.org/160484
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22208 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
test.
Note: the fix is trivial, but adding support for a test required teaching the
FileHandler of testserver to consume a post body.
BUG=16832
TEST=covered by unit test
R=abarth
Review URL: http://codereview.chromium.org/149710
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22100 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change might introduce flakiness and test hangs, but we have
infrastructure in place to quickly detect it.
TEST=none
http://crbug.com/18036
Review URL: http://codereview.chromium.org/159614
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22069 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
they are sent.
A good portion of this CL is to support the new UI test.
The IPC to notify the renderer of a redirect now includes a ResponseInfo struct
allowing WebURLLoaderImpl to provide detailed response info (including response
headers) to WebKit. This isn't strictly necessary, but I thought I'd include
this to make the code more future proof.
A cross origin restriction is added to SyncResourceHandler::OnRequestRedirected
that mimics the code in WebCore/platform/network/cf/ResourceHandleCFNet.cpp.
This is most unfortunate, and I filed a bug at bugs.webkit.org about the
similar duplication of logic in WebCore.
There seemed to be enough code paths leading to request cancellation at the
ResourceDispatcher level that I couldn't easily ensure that a request only gets
cancelled once. So, I added an is_cancelled flag to record if it is not
necessary to send a ViewHostMsg_CancelRequest IPC. This avoids some warnings
in the ResourceDispatcherHost.
To support my UI test, I needed to change URLRequestMockHttpJob to know how to
serve redirects. I moved URLRequestHttpJob::IsRedirectResponse to its base
class, URLRequestJob so that the implementation could be shared. This revealed
a minor bug in URLRequest. We were never resetting response_info_ upon
following a redirect. I added this code consolidated similar code from
URLRequest::Redirect and URLRequest::RestartWithJob into a new PrepareToRestart
method.
To support my UI test, I added a "hit count" field to URLRequestFilter, and I
added an associated automation IPC to query the value. The test was a bit
challenging to write because there is no way to tell the difference from JS.
Before and after, it appears to JS as though the cross-origin redirect failed.
However, the server can see the extra redirect request. So, I simply record
the number of hits against URLs of the form http://mock.http/foo, and use that
to observe if any extra requests were made. I implemented the new IPC message
by extending the AutomationResourceMessageFilter. This allowed me to trap the
IPC message on the IO thread where it is safe to probe the URLRequestFilter. I
then changed the implementation of AutomationMsg_SetFilteredInet to work
similarly.
I revised URLRequestMockHTTPJob::GetOnDiskPath to support ports. This actually
allowed me to reuse URLRequestMockHTTPJob to service URLs in different security
origins. My test redirects from http://mock.http/ to http://mock.http:4000/.
Please see the comments in cross-origin-redirect-blocked.html for details about
how the test functions.
R=brettw,wtc
BUG=16413
TEST=covered by resource_dispatcher_host_uitest.cc
Review URL: http://codereview.chromium.org/159370
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22067 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
to ChromeURLRequestContext.
BUG=16932
TEST=none
Review URL: http://codereview.chromium.org/159519
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21874 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Give Automation better visibility and control over navigations.
Also, make it possible for automation to implement a dummy cookie
store to go with dummy request serving over automation.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/159189
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21836 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
The header tried overriding a non-virtual method, changing its visibility.
By the way, there was no implementation provided for this "overriden" method.
I just hit that while fixing other things.
Review URL: http://codereview.chromium.org/160173
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21730 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Blocked requests now return an error status so that the Chrome throbber does
not spin indefinitely when blocking URL requests.
This code shall be replaced with resource substitution next but gives a better
experience until then. Same goes for the added type-based interception.
TEST=none
BUG=16932
Review URL: http://codereview.chromium.org/159214
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21536 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I chose to add an out parameter to OnReceivedRedirect because it allows for the
default behavior to remain the same.
I considered adding a ContinueAfterRedirect method that all OnReceivedRedirect
implementations would need to call, but this caused one annoying problem: In
the case of a ChromePlugin, it is possible for the URLRequest to get deleted
inside the handler for the redirect. This would make it hard to subsequently
call a method on the URLRequest since I would need to have a way to determine
if the URLRequest had been deleted.
TEST=covered by unit tests
BUG=16413,6442
R=eroman,wtc
Review URL: http://codereview.chromium.org/155897
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21417 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
| |
BUG=http://crbug.com/17126
TEST=net_unittests
Review URL: http://codereview.chromium.org/159034
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21234 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
ftp_directory_parser.{h,cc}.
The patch is contributed by Ibrar Ahmed <ibrar.ahmad@gmail.com>.
Original review URL: http://codereview.chromium.org/126096
R=wtc
BUG=http://crbug.com/4965
TEST=none
Review URL: http://codereview.chromium.org/149772
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21003 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
BUG=NONE
TEST=NONE
TBR=wtc
Review URL: http://codereview.chromium.org/149726
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20818 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(1) Extract HostResolver to an interface.
The existing concrete implementation is now named HostResolverImpl. This makes it possible to create mocks with more complex behavior (i.e. choose via rules if response will be sync vs async).
(2) Transform HostMapper into HostResolverProc.
Conceptually HostResolverProc maps a hostname to a socket address, whereas HostMapper mapped a hostname to another hostname (so you were still at the mercy of the system's host resolver). With HostResolverProc you can specify the exact AddressList, making it possible to run tests requiring IPv6 socketaddrs on systems (like WinXP) that don't actually support it.
(3) Add a MockHostResolver implementation of HostResolver.
This replaces the [ScopedHostMapper + RuleBasedHostMapper + HostResolver] combo. It is less clunky and a bit more expressive.
BUG=http://crbug.com/16452
R=willchan
TEST=existing
Review URL: http://codereview.chromium.org/149511
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20795 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
handling (drag'n'drop and opening from the file list).
For the local file listing, use the OS file system encoding.
For the FTP directory listing, use ICU's encoding detector.GetDirectoryListingEntry and GetDirectoryLisingHeader were changed to accept string16 for file/directory names. To the former, a new parameter (|raw_bytes|) was added. It can be used to make a FTP request to a file with a non-ASCII name encoded in a legacy encoding.
For the local file handling on Windows, get rid of the code for 'doubly converted' UTF-8 in FileURLToFilePath, which led to issue 4619 and add a few cases to NetUtil*.FileURLConversion* test.
In addition, add
CodepageToUTF16 and UTF16ToCodepage along with a new unittest (ConvertBetweenCodepageAndUTF16) that shares the same set of case as ConvertBetweenCodepageAndWide. The test cases were expanded and revised a bit.
BUG=2939,13229,4619
http://crbug.com/2939 http://crbug.com/13229 http://crbug.com/4619
TEST=1. Pass URLRequest*.FTP* (net_unittests)
2. Pass StringUtiltTest.ConvertBetweenCode*
3. Pass NetUtil*.GetDirectoryLis* (net_unittests)
4. Open a local directory containing files with non-ASCII names and they're displayed correctly in the directory list. On Windows and Mac OS X, it should always work. On Linux, your locale encoding (as returned by nl_langinfo(CODESET)) should match the actual encoding used in your filename.
5a. Pass NetUtil*.FileURL* (net_unittests) with the default codepage set to 1252 and 932.
5b. Make a file named 'caf챕.txt' on Windows and see if it can be opened both by clicking in the directory listing page of Chrome and by drag'n'drop. Test this with the default OS code pages set to Windows-1252, Windows-1251 (Russian) and Windows-932 (Japanese).
Review URL: http://codereview.chromium.org/151065
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20331 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
|
| |
Most of the changes are cosmetic, but there is also a
memory leak in CreateExpiredServer.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/153001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19788 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
| |
r=mbelshe
Review URL: http://codereview.chromium.org/149119
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19491 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
|
|
|
|
|
| |
This way it can be properly shared between the url request contexts, and the dns prefetcher, and dns observer.
BUG=http://crbug.com/14664
TEST=existing unit tests.
Review URL: http://codereview.chromium.org/149053
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19451 0039d316-1c4b-4281-b951-d872f2087c98
|
|
|
|
|
|
| |
Review URL: http://codereview.chromium.org/147242
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19432 0039d316-1c4b-4281-b951-d872f2087c98
|