summaryrefslogtreecommitdiffstats
path: root/base/pickle.h
Commit message (Collapse)AuthorAgeFilesLines
* Remove the rest of #pragma once in one big CL.ajwong@chromium.org2012-07-111-1/+0
| | | | | | | | | For context see this thread: https://groups.google.com/a/chromium.org/forum/?fromgroups#!topic/chromium-dev/RMcVNGjB4II TBR=thakis,pkasting,jam git-svn-id: svn://svn.chromium.org/chrome/trunk/src@146163 0039d316-1c4b-4281-b951-d872f2087c98
* Make the serialization of IPC::Messages inside other IPC::Messages independentbrettw@chromium.org2012-06-291-0/+13
| | | | | | | | | | | | | | of the platform. This is necessary for sending nested messages between nacl (which the IPC system thinks is posix and so has extra header goo) and a Windows client app (which doesn't have this stuff). BUG= Review URL: https://chromiumcodereview.appspot.com/10667002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@144840 0039d316-1c4b-4281-b951-d872f2087c98
* Initial implementation of an IPC adapter to expose Chrome IPC to Native Client.brettw@chromium.org2012-03-301-4/+5
| | | | | | | | | | | This provides an implementation of sendmsg and recvmsg approxinately to what we think NaCl will expose to Chrome. Since NaCl isn't ready yet in this regard, it's still a bit speculative. And there is no support for sending handles across which will be the tricky part. TEST=included unit test BUG=none Review URL: https://chromiumcodereview.appspot.com/9863005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@129981 0039d316-1c4b-4281-b951-d872f2087c98
* Remove Pickle::WriteSize() now that it has no remaining callers. Also renamemdm@chromium.org2012-03-231-8/+6
| | | | | | | | | | | Pickle::WriteLong() to WriteLongUsingDangerousNonPortableLessPersistableForm() and add a strongly-worded comment against its use; it is used only for IPC which is safe. (These methods write variable amounts of data to pickles, depending on architecture, and aren't safe if pickles are persisted.) Review URL: http://codereview.chromium.org/9641005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@128347 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor Pickle Read methods to use higher performance PickleIterator.jbates@chromium.org2012-03-071-38/+118
| | | | | | | | | | | | | | | | There was a lot of redundant error checking and initialization code in all Pickle Read methods because of the void** iterator type. This change replaces the void* iterator with PickleIterator, which encapsulates the read pointer so that less error checking and initialization code is needed for reading. PickleIterator has all the necessary data to do the actual reading. The advantage of having it provide Read methods (as opposed to leaving them solely in the Pickle interface) is that the callers do not need to pass around the const Pickle* once they have a PickleIterator. Followup CLs will refactor the call sites to remove const Pickle* arguments where they are now unnecessary. Then the Pickle::Read* methods can be removed entirely. The alternative approach would have been to change the Pickle::Read methods to non-const and remove the iterator parameter (making Read methods advance an internal read pointer). Unfortunately, the const Read with iterator design is entrenched throughout the chromium code, making this a much more complex change with the same performance outcome. BUG=13108 Review URL: https://chromiumcodereview.appspot.com/9447084 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@125447 0039d316-1c4b-4281-b951-d872f2087c98
* Add comment about use of virtualjar@chromium.org2011-09-251-0/+5
| | | | | | | | | | | See request in comments within: http://codereview.chromium.org/159800/ r=wtc Review URL: http://codereview.chromium.org/7967018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@102672 0039d316-1c4b-4281-b951-d872f2087c98
* Rename BASE_API to BASE_EXPORT.darin@chromium.org2011-08-051-2/+2
| | | | | | | R=rvargas Review URL: http://codereview.chromium.org/7461141 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@95618 0039d316-1c4b-4281-b951-d872f2087c98
* Base: A few more files using BASE_API (for base.dll)rvargas@google.com2011-03-251-1/+2
| | | | | | | | BUG=76996 TEST=none Review URL: http://codereview.chromium.org/6733031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@79426 0039d316-1c4b-4281-b951-d872f2087c98
* More DCHECK() updates. A mixture of _EQ and _GE.mhm@chromium.org2011-03-011-2/+2
| | | | | | | | Bug=58409 Review URL: http://codereview.chromium.org/6469070 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76343 0039d316-1c4b-4281-b951-d872f2087c98
* Propagate the remote socket address to URLRequest and to ↵bryner@chromium.org2011-02-221-0/+4
| | | | | | | | | | | | | | | | ViewHostMsg_FrameNavigate. This will be used to run pre-classification checks for client-side phishing detection, and will also enable the socket address to be exposed via the webRequest extension API. This is adapted from the original patch by pmarks on http://codereview.chromium.org/6369003/ . BUG=51663 TEST=added socket address checks to various unittests Review URL: http://codereview.chromium.org/6488010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@75620 0039d316-1c4b-4281-b951-d872f2087c98
* Change size() function to return a size_t so that result size is not ↵mrossetti@chromium.org2011-01-281-2/+1
| | | | | | | | | | | inadvertently truncated. BUG=None TEST=Ran existing unit tests and trybots. Review URL: http://codereview.chromium.org/6386008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73001 0039d316-1c4b-4281-b951-d872f2087c98
* Check that we've got a complete header before accessing its fields.glider@chromium.org2011-01-261-0/+1
| | | | | | | | | | | | | This patch was prepared by Evgeniy Stepanov (eugenis@chromium.org) and reviewed at http://codereview.chromium.org/6353010/ BUG=70376 TEST=none TBR=darin,willchan Review URL: http://codereview.chromium.org/6347013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@72634 0039d316-1c4b-4281-b951-d872f2087c98
* Start sorting methods in class declarations.erg@google.com2011-01-071-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | A lot of our headers are a mess and aren't organized. Impose the following order on files in the base/ directory: class Blah { each public/protected/private section: typedefs; enums; static constants; ctors; dtors; methods; overridden virtual methods; data members; }; BUG=68682 TEST=compiles Review URL: http://codereview.chromium.org/6081007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70749 0039d316-1c4b-4281-b951-d872f2087c98
* Pickle: handle invalid data on 64 bit systems.rvargas@google.com2010-11-151-1/+3
| | | | | | | | | | | | There was a problem with pointer arithmetic for 64 bit systems so invalid data was not properly detected. Now we do explicit tests. BUG=56449 TEST=base_unittests Review URL: http://codereview.chromium.org/4716006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@66149 0039d316-1c4b-4281-b951-d872f2087c98
* `#pragma once` for app, base, chrome, gfx, ipc, net, skia, viewsthakis@chromium.org2010-07-261-0/+1
| | | | | | | | | BUG=50273 TEST=everything still builds, build is 10% faster on windows, same speed on mac/linux TBR: erg git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53716 0039d316-1c4b-4281-b951-d872f2087c98
* [GTTF] Add FRIEND_TEST_ALL_PREFIXES, a FRIEND_TEST replacementphajdan.jr@chromium.org2010-06-011-4/+4
| | | | | | | | | | | that works with all test prefixes (DISABLED, FLAKY, FAILS). TEST=none BUG=44549 Review URL: http://codereview.chromium.org/2439001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@48634 0039d316-1c4b-4281-b951-d872f2087c98
* Take out intptr_t IPC serialization support to prevent people from sending ↵jam@chromium.org2010-02-091-4/+0
| | | | | | | | pointers between trusted and untrusted processes. Move HWNDs and other Windows HANDLEs serialization to use 32 bits even on 64 bit platforms since that's all that's needed. Review URL: http://codereview.chromium.org/565001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38455 0039d316-1c4b-4281-b951-d872f2087c98
* Add Pickle::Read/WriteUint64.thestig@chromium.org2009-10-281-0/+4
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/297011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30320 0039d316-1c4b-4281-b951-d872f2087c98
* Add short circuit case for self assignment, and add virtual destructorjar@chromium.org2009-08-071-1/+1
| | | | | | | | | | | | | | | | | | | Pickle is a base class of Message, which has a virtual destructor, so it is better to have Pickle have a virtual destructor as well. Add more defensive code in the case of self assignment. **IF** self assignment was used, and the target was read-only, then the existing code would have a memory fault. I don't think this is currently possible in use cases, but the defensize code is much better. (per suggestion from CPU on last CL). BUG=17027 BUG=17088 r=cpu Review URL: http://codereview.chromium.org/159800 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22826 0039d316-1c4b-4281-b951-d872f2087c98
* NO CODE CHANGEdeanm@chromium.org2009-03-101-1/+0
| | | | | | | | | Normalize end of file newlines in base/. All files end in a single newline. Review URL: http://codereview.chromium.org/42011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11329 0039d316-1c4b-4281-b951-d872f2087c98
* Update clipboard classes to use string16 and FilePath instead of wstring.estade@chromium.org2009-03-041-0/+3
| | | | | | | | | | Update callers as well. This patch builds on a patch by mark.a.lindner@gmail.com which can be found at http://codereview.chromium.org/28294 Review URL: http://codereview.chromium.org/27370 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10860 0039d316-1c4b-4281-b951-d872f2087c98
* * Bring up render_mesages.cc on POSIX.jeremy@chromium.org2008-12-291-0/+4
| | | | | | | | | * Add Pickle::Read/WriteUint32 & ParamTraits<uint32>. * Removed NSEvent from WebInputEvent since it appears not to be needed anymore. Review URL: http://codereview.chromium.org/16479 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7484 0039d316-1c4b-4281-b951-d872f2087c98
* Use a more compact license header in source files.license.bot2008-08-241-28/+4
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1287 0039d316-1c4b-4281-b951-d872f2087c98
* Adds capabilities for IPC messages of type long, for the primary purpose of ↵klink@google.com2008-08-221-0/+4
| | | | | | accessibility related communication. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1263 0039d316-1c4b-4281-b951-d872f2087c98
* Remove class scoping operator from Pickle method declaration.deanm@google.com2008-08-111-1/+1
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@641 0039d316-1c4b-4281-b951-d872f2087c98
* Reapply 508 to determine if it was indeed the cause of the ↵maruel@google.com2008-08-071-6/+0
| | | | | | webkit-release-playback failure. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@518 0039d316-1c4b-4281-b951-d872f2087c98
* Revert part of r508, it may have broken webkit-release-playback.deanm@google.com2008-08-071-0/+6
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@514 0039d316-1c4b-4281-b951-d872f2087c98
* Some cross platform changes and general cleanups to Pickle.deanm@google.com2008-08-071-6/+0
| | | | | | | | | | | - Clean up TrimWriteData, and remove the unneeded VariableLengthBuffer struct. Modify a test to slightly test TrimWriteData, but it probably deserves more. - Remove unneeded includes in pickle_unittest, including windows.h. - According to 3.5 of the C++ standard, CustomHeader could not be used as a template argument, because it had no linkage. This now builds on GCC. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@508 0039d316-1c4b-4281-b951-d872f2087c98
* Fix base::DIR_SOURCE_ROOT path calculation.maruel@google.com2008-08-061-4/+4
| | | | | | | | | Add missing header files to base.vcproj. Fix thread local storage implicit destructor call on Windows x64. Fix build compilation issues in x64 with third party headers. Fix Pickle for x64, the header doesn't need to be size_t, uint32 ought to be sufficient for the object. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@450 0039d316-1c4b-4281-b951-d872f2087c98
* Add base to the repository.initial.commit2008-07-261-0/+259
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8 0039d316-1c4b-4281-b951-d872f2087c98