summaryrefslogtreecommitdiffstats
path: root/net/base
Commit message (Collapse)AuthorAgeFilesLines
* Unignore most warnings on POSIX in build/SConscript.main.evanm@google.com2008-09-161-3/+2
| | | | | | | | | BUG=2053 Patch from Paweł Hajdan jr <phajdan.jr@gmail.com>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2272 0039d316-1c4b-4281-b951-d872f2087c98
* memcpy cannot overlap, move to memmove.deanm@google.com2008-09-162-2/+2
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2257 0039d316-1c4b-4281-b951-d872f2087c98
* Simple unit test, written mostly just to become familiar with the code.dkegel@google.com2008-09-151-0/+118
| | | | | | | I've addressed the comments and added the test to the visual studio project. I'll commit when the tree opens. Review URL: http://codereview.chromium.org/3049 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2249 0039d316-1c4b-4281-b951-d872f2087c98
* An early optimization in std::pair<> in Visual Studio 2008 Service Pack 1 ↵maruel@google.com2008-09-151-0/+9
| | | | | | | | makes it requires a default constructor on its members. Review URL: http://codereview.chromium.org/2851 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2212 0039d316-1c4b-4281-b951-d872f2087c98
* Add the EV metadata for two GlobalSign root CA certificates.wtc@google.com2008-09-111-0/+11
| | | | | | | | R=ifette BUG=2058 Review URL: http://codereview.chromium.org/2406 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2098 0039d316-1c4b-4281-b951-d872f2087c98
* Remove all but one place in this file where we returnwtc@google.com2008-09-111-2/+3
| | | | | | | | | | | | ERR_FAILED. In the remaining place, log the original Win32 error code to help diagnose a failure in the field. R=darin Review URL: http://codereview.chromium.org/1927 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2066 0039d316-1c4b-4281-b951-d872f2087c98
* Fix IDNtoUnicode and unittest. jungshik@google.com2008-09-112-4/+9
| | | | | | | | | | | | | | | | | | | | 1. Check whether uloc_getdata returns the default locale because an invalid or unsupported (not a part of ICU data file we use) locale is passed. 2. Replace 'se' with 'sv' in IDNToUnicode test and change the corresponding test result to true. U+00C4 IS used in Swedish, but the result was set to false because the test results were machine generated with the same typo ('se' in place of 'sv') under en_US.UTF-8 locale on Linux and we ran this test only on Windows with en_US locale. 1st part of patch is by Matthias Reitinger <reimarvin@gmail.com> BUG=1153 TEST=NetUtilTest.IDNToUnicode passes in various locales, C, en_US, en_US.utf8, ja_JP.utf8, sv_SE.utf8, hi_IN.utf8, ru_RU.utf8, fr_CA Review URL: http://codereview.chromium.org/1655 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2052 0039d316-1c4b-4281-b951-d872f2087c98
* Do a better job at bounding HexToInt.deanm@chromium.org2008-09-101-1/+1
| | | | | | | http://codereview.chromium.org/1703 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1994 0039d316-1c4b-4281-b951-d872f2087c98
* Use gcc 4.2 for the Mac build. Fix up new warnings and errors pointed outmark@chromium.org2008-09-104-47/+44
| | | | | | | | | | by gcc 4.2: warning: 'C' has a field 'C::m_' whose type uses the anonymous namespace warning: missing braces around initializer for 'S' error: extra qualification 'C::' on member 'm' Review URL: http://codereview.chromium.org/1675 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1955 0039d316-1c4b-4281-b951-d872f2087c98
* Build host_resolver on the Macmmentovai@google.com2008-09-093-11/+6
| | | | | | Review URL: http://codereview.chromium.org/1839 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1896 0039d316-1c4b-4281-b951-d872f2087c98
* Get MIME stuff working minimally to the point where we haveerg@google.com2008-09-081-0/+40
| | | | | | | | | unit tests passing. B=1315 Review URL: http://codereview.chromium.org/1824 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1866 0039d316-1c4b-4281-b951-d872f2087c98
* The previous fix doesn't work. We should continuewtc@google.com2008-09-051-4/+10
| | | | | | | | | | | decrypting if there is still extra data to decrypt, and read more if there is no data to decrypt. R=darin BUG=b/1329345,b/1329363 Review URL: http://codereview.chromium.org/480 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1814 0039d316-1c4b-4281-b951-d872f2087c98
* This fixes the "passing NULL to non-pointer argument" warning when compiling ↵mmoss@google.com2008-09-051-1/+1
| | | | | | | | with gcc 4.1, and is consistent with the way EXPECT_EQ uses NULL elsewhere in Chrome. Review URL: http://codereview.chromium.org/267 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1813 0039d316-1c4b-4281-b951-d872f2087c98
* Modify HostResolver slightly to build on posix as well as windows.dkegel@google.com2008-09-052-0/+51
| | | | | | Review URL: http://codereview.chromium.org/403 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1799 0039d316-1c4b-4281-b951-d872f2087c98
* Fix a crash caused by a NULL FILETIME when creating ftptc@google.com2008-09-042-3/+42
| | | | | | | | | directory listings. BUG=1350006 Review URL: http://codereview.chromium.org/419 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1722 0039d316-1c4b-4281-b951-d872f2087c98
* If we didn't read enough to be able to decrypt anything,wtc@google.com2008-09-041-0/+4
| | | | | | | | | | | go back to read more rather than reporting 0 bytes read, which would be interpreted as EOF. R=darin BUG=b/1329345,b/1329363 Review URL: http://codereview.chromium.org/217 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1705 0039d316-1c4b-4281-b951-d872f2087c98
* Fix an out of band read when parsing a URL component of just "%". The ↵deanm@google.com2008-09-032-3/+3
| | | | | | | | calculation of max_digit_index is unsigned, and was underflowing when max was less than 2. BUG=122 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1677 0039d316-1c4b-4281-b951-d872f2087c98
* Normalize newlines to LF in netmmentovai@google.com2008-09-024-196/+196
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1647 0039d316-1c4b-4281-b951-d872f2087c98
* Initial pass at simple event tracing. I added a few traces to tcp_socket ↵erikkay@google.com2008-09-021-0/+14
| | | | | | | | | | | | and test_shell to get an idea of what a simple trace might look like. Here's a sample output line: 11:24:19.660604 0x1e278:0x1e24c BEGIN url.load [0x5 http://mail.google.com/mail/] <E:\src\cr\src\webkit\tools\test_shell\test_webview_delegate.cc:189> format is:hh:mm:ss.us pid:tid TYPE NAME [id, extra] <file:line> git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1641 0039d316-1c4b-4281-b951-d872f2087c98
* Unit tests can't access the outside world.maruel@google.com2008-09-021-4/+8
| | | | | | TBR=wtc git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1638 0039d316-1c4b-4281-b951-d872f2087c98
* Fix net_unittests hang observed on Vista. It turns out that a subpump wasdarin@google.com2008-08-291-11/+0
| | | | | | | | | | | | | | | | | being run within shell32, which was causing our kHaveWorkMsg to get dispatched. However, because that was occuring outside the context of a MessagePump::Run call, the handler for kHaveWorkMsg was returning early. Unfortunately, this means that it was failing to reset the have_work_ sentinel to 0. Because of that future calls to ScheduleWork would always be a no-op (as they return early when have_work_ is already set to 1). The proper fix is to just re-order the calls so that ProcessPumpReplacementMessage always runs in response to kHaveWorkMsg, but we still suppress calling DoWork until we are inside MessagePump::Run. TBR=rvargas,jar git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1544 0039d316-1c4b-4281-b951-d872f2087c98
* Hack to keep vista net_unittests from hanging while I investigate a proper fix.darin@google.com2008-08-291-0/+11
| | | | | | | TBR=rvargas git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1540 0039d316-1c4b-4281-b951-d872f2087c98
* Simplify OneShotTimer and RepeatingTimer. Fix up all consumers.darin@google.com2008-08-282-14/+11
| | | | | | | | | | | | | | | | | | | | | | | | Major changes: OneShotTimer and RepeatingTimer become template classes that no longer require a Task or a Timer object. They just use PostDelayedTask. Under the hood that still uses a Timer object. The API is much simpler for consumers as they now no longer need to worry about allocating a Task or managing the lifetime of the object pointer held by the Task. I added some new unit tests to timer_unittest.cc to cover the API. I preserved the old TimerManager / Timer API for now, but I plan to soon kill it. R=brettw BUG=1346553 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1502 0039d316-1c4b-4281-b951-d872f2087c98
* Move std::string16 to base::string16. Don't pollute the std namespace. Don'tmmentovai@google.com2008-08-272-5/+5
| | | | | | assume that all string types can be represented as std::basic_string<CHAR>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1464 0039d316-1c4b-4281-b951-d872f2087c98
* On .mm files in net and base:mmentovai@google.com2008-08-271-31/+6
| | | | | | | | - Update the license boilerplate - Set svn:eol-style properly - Get rid of trailing whitespace git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1455 0039d316-1c4b-4281-b951-d872f2087c98
* Fix the net_perftests to work again.darin@google.com2008-08-271-1/+1
| | | | | | | | | Since only one test needed a MessageLoop, I decided to only give that single test a MessageLoop. I used a MessageLoopForIO (subclass of MessageLoop) for future use when the disk cache leverages MessageLoopForIO for asynchronous IO. TBR=rvargas git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1428 0039d316-1c4b-4281-b951-d872f2087c98
* Allow consumers of MessageLoop to specify the type of MessageLoop they want.darin@google.com2008-08-262-2/+60
| | | | | | | | | | | | | | | | This CL introduces a Type enum to MessageLoop, and I also created subclasses of MessageLoop corresponding to the non-default types: MessageLoopForIO and MessageLoopForUI. I moved all of the platform-specific MessageLoop APIs onto either MessageLoopForIO or MessageLoopForUI. MessageLoopForIO gets the Watcher API, and MessageLoopForUI gets the Observer and Dispatcher APIs. Under the hood, both are implemented in terms of MessagePumpWin, but that will change in a future CL. The Thread class is changed to allow the consumer to specify the Type of MessageLoop they want to have setup on the created thread. I re-organized message_loop_unittest.cc and timer_unittest.cc so that I could exercise all (or most) of the tests against each type of MessageLoop. Note: I know that "explicit MessageLoop(Type type = TYPE_DEFAULT);" is in violation to the style-guide's restriction against default arguments. I'm working on finding a decent solution to that problem. Please ignore this issue for now. The corresponding chrome/ changes are coming in a separate CL due to Reitveld data size limitations. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1362 0039d316-1c4b-4281-b951-d872f2087c98
* Implement SSL tunneling through a proxy server.wtc@google.com2008-08-252-0/+4
| | | | | | | | | | | | | | Add several states to HttpNetworkTransaction for the HTTP CONNECT method and the SSL Connect (handshake) after the tunnel is connected. Add the error code ERR_TUNNEL_CONNECTION_FAILED for failure to connect a tunnel. R=darin BUG=1272555 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1329 0039d316-1c4b-4281-b951-d872f2087c98
* We can link with secur32.lib and call the SSPI functions directly.wtc@google.com2008-08-251-48/+18
| | | | | | | | | Add secur32.dll to chrome.dll.deps as a new dependency of chrome.dll. R=maruel BUG=1272567 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1310 0039d316-1c4b-4281-b951-d872f2087c98
* Use a more compact license header in source files.license.bot2008-08-24102-3036/+588
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1287 0039d316-1c4b-4281-b951-d872f2087c98
* Back out the previous checkin because buildbot detectswtc@google.com2008-08-221-18/+48
| | | | | | | | | that chrome.dll is now dependent on secur32.dll. we need to update chrome.dll.deps. TBR=sky git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1266 0039d316-1c4b-4281-b951-d872f2087c98
* Fix spurious gcc warning dkegel@google.com2008-08-221-1/+1
| | | | | | | net/base/net_util.cc:176: warning: suggest parentheses around && within || git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1261 0039d316-1c4b-4281-b951-d872f2087c98
* We can link with secur32.lib and call the SSPI functions directly.wtc@google.com2008-08-221-48/+18
| | | | | | | | | | | The Platform SDK sample code loads the DLL and looks up the function pointer table dynamically, probably because it was written back when Win 9x and NT used different DLLs (secur32.dll and security.dll). R=maruel,darin BUG=1272567 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1256 0039d316-1c4b-4281-b951-d872f2087c98
* Impl of platform mime typing for Mac.avi@google.com2008-08-221-6/+43
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1238 0039d316-1c4b-4281-b951-d872f2087c98
* Use PlatformTest to manage autorelease pools in net tests that use the path ↵mmentovai@google.com2008-08-222-4/+18
| | | | | | service git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1233 0039d316-1c4b-4281-b951-d872f2087c98
* Move FileURLToFilePath into platform specific files. Most of the logic in ↵tc@google.com2008-08-224-76/+219
| | | | | | this function is specific to windows' file system. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1211 0039d316-1c4b-4281-b951-d872f2087c98
* Enable -Werror on the Mac. Fix two more warnings just added to our build. ↵mmentovai@google.com2008-08-221-3/+3
| | | | | | Note that the targets for libskia and libicuuc still exclude themselves from -Werror. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1205 0039d316-1c4b-4281-b951-d872f2087c98
* This line should not have ever changedmmentovai@google.com2008-08-211-1/+1
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1199 0039d316-1c4b-4281-b951-d872f2087c98
* Fix the final gcc warnings in base and net. Provide some macros to ↵mmentovai@google.com2008-08-212-13/+10
| | | | | | selectively disable MSVC warnings. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1194 0039d316-1c4b-4281-b951-d872f2087c98
* Make upload_data not be windows specific. Add it to the SCons build.tc@google.com2008-08-212-11/+5
| | | | | | | Also add mime_sniffer_unittest which already passes. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1178 0039d316-1c4b-4281-b951-d872f2087c98
* Add net_util* to the SCons build. Fixes some ICU UChar issues in net_util. ↵tc@google.com2008-08-213-44/+64
| | | | | | | | | Also disable NetUtilTest.FileURLConversion because it seems to have Windows specific output (is this the right thing to do?). The other changes to net_util_unittest is to get arraysize to work (see the comment in base/basictypes.h). git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1168 0039d316-1c4b-4281-b951-d872f2087c98
* Port cookie_monster, net_util, and registry_controlled_domain to POSIXish ↵mmentovai@google.com2008-08-217-158/+193
| | | | | | platforms git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1164 0039d316-1c4b-4281-b951-d872f2087c98
* Mark static method defined in header as inlinemmentovai@google.com2008-08-211-4/+4
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1162 0039d316-1c4b-4281-b951-d872f2087c98
* Back out r1154 due to test failuresmmentovai@google.com2008-08-217-185/+158
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1156 0039d316-1c4b-4281-b951-d872f2087c98
* Port cookie_monster, net_util, and registry_controlled_domain to POSIXish ↵mmentovai@google.com2008-08-217-158/+185
| | | | | | platforms git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1154 0039d316-1c4b-4281-b951-d872f2087c98
* Final character conversions for net_util.paulg@google.com2008-08-201-4/+17
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1132 0039d316-1c4b-4281-b951-d872f2087c98
* M net/base/cookie_monster.hawalker@google.com2008-08-201-2/+2
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1131 0039d316-1c4b-4281-b951-d872f2087c98
* Fix some character conversions and Mac compile errors for net_util.cc.paulg@google.com2008-08-202-18/+39
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1112 0039d316-1c4b-4281-b951-d872f2087c98
* Quick fix; it's a struct not a class.avi@google.com2008-08-201-1/+1
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1104 0039d316-1c4b-4281-b951-d872f2087c98
* Fixing extended verification code for non-windowsavi@google.com2008-08-202-2/+2
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1101 0039d316-1c4b-4281-b951-d872f2087c98