summaryrefslogtreecommitdiffstats
path: root/ipc
Commit message (Collapse)AuthorAgeFilesLines
* Add support for exporting IPC messages from component DLLs.darin@chromium.org2011-08-265-313/+325
| | | | | | | | | | | | | | | | | | | | | | This removes MessageWithTuple and MessageWithReply since it is not easy to export a class that inherits from a template specialization. The functionality of those classes are split now between new classes, MessageSchema and SyncMessageSchema, and being declared inline via macros. The key point is that we want to avoid inlining the constructor and Read functions for messages. That avoids code bloat since those functions contain all of the parameter serialization and deserialization code. Those are the functions that we really want to have contained with component DLLs. To export IPC messages from a DLL, it is necessary to #define IPC_MESSAGE_EXPORT above message declarations. You can see this in action here: http://codereview.chromium.org/7687005/diff/41012/ppapi/proxy/ppapi_messages.h Review URL: http://codereview.chromium.org/7768001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@98491 0039d316-1c4b-4281-b951-d872f2087c98
* There are times on the Mac when pipe names of 0 length may occur. Let the ↵dmaclach@chromium.org2011-08-252-3/+21
| | | | | | | | | | | | | caller handle the error instead of aborting here. BUG=75518 TEST=BUILD Review URL: http://codereview.chromium.org/7743001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@98225 0039d316-1c4b-4281-b951-d872f2087c98
* Clean up a comment in ipc_message_macros.hsteveblock@chromium.org2011-08-231-4/+4
| | | | | | | | | | BUG= TEST= Review URL: http://codereview.chromium.org/7709004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@97844 0039d316-1c4b-4281-b951-d872f2087c98
* This patch caused Chrome to be unable to load any web pages on Chrome OS.satorux@chromium.org2011-08-237-113/+13
| | | | | | | | | | | | | BUG=chromium-os:19468 TEST=confirm chrome loads pages Revert "Fix IPC OnChannelConnected() to send correct PID on Linux/CrOS" This reverts commit 92321e01ba42f2d0e9508e921f8b440ac0b5319f. Review URL: http://codereview.chromium.org/7712022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@97811 0039d316-1c4b-4281-b951-d872f2087c98
* Fix IPC OnChannelConnected() to send correct PID on Linux/CrOSjamescook@chromium.org2011-08-197-13/+113
| | | | | | | | | | | | | | | | | | | | Sandboxed renderers on Linux/CrOS are in a PID namespace, so they don't know their own global PID. Thus the PID sent in the IPC channel Hello message contains an unexpected value, which is used in the OnChannelConnected() callback into chrome. This causes problems like the Task Manager not showing any data for FPS, JavaScript memory and image cache memory. The task manager is attempting to use the PID/process handle from BrowserMessageFilter, which got it from IPC::Channel::Listener::OnChannelConnected(), and it doesn't match the global PID of each renderer. BUG=70179 TEST=manual, open a few tabs, then open task manager, right-click to turn on JavaScript memory and image memory. Verify there are non-zero values for FPS, JavaScript memory, image cache memory Review URL: http://codereview.chromium.org/7661004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@97481 0039d316-1c4b-4281-b951-d872f2087c98
* Fix IPC marshalling of dictionaries with dots in their key names.kalman@chromium.org2011-08-192-1/+2
| | | | | | | | | | BUG= TEST=unit test Review URL: http://codereview.chromium.org/7671057 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@97435 0039d316-1c4b-4281-b951-d872f2087c98
* ipc: rename a variable to make code clearerevan@chromium.org2011-08-161-7/+7
| | | | | | | | | It took me a while to understand this function because filters_ and filters represented two very different things. Review URL: http://codereview.chromium.org/7670006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@97037 0039d316-1c4b-4281-b951-d872f2087c98
* Tag IPC::Channel::Listener implementations with OVERRIDEevan@chromium.org2011-08-163-12/+12
| | | | | | Review URL: http://codereview.chromium.org/7661031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@97021 0039d316-1c4b-4281-b951-d872f2087c98
* Create ipc.dll.darin@chromium.org2011-08-1514-50/+90
| | | | | | Review URL: http://codereview.chromium.org/7633042 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@96820 0039d316-1c4b-4281-b951-d872f2087c98
* Add MessageLoopProxy::currentnduca@chromium.org2011-08-152-2/+2
| | | | | | Review URL: http://codereview.chromium.org/7583053 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@96819 0039d316-1c4b-4281-b951-d872f2087c98
* Fix NamedProxyLauncher on windows. Wait for the named pipe to be connectable.kkania@chromium.org2011-08-096-2/+49
| | | | | | | | | | | Enable NamedInterfaceTest on windows. BUG=chromium-os:8515 TEST=none Review URL: http://codereview.chromium.org/7486007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@95957 0039d316-1c4b-4281-b951-d872f2087c98
* ipc: remove an unused function prototypeevan@chromium.org2011-08-051-5/+0
| | | | | | Review URL: http://codereview.chromium.org/7541054 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@95678 0039d316-1c4b-4281-b951-d872f2087c98
* base: Remove using declaration of BinaryValue as it's no longer necessary.tfarina@chromium.org2011-08-051-2/+3
| | | | | | | | | | | BUG=None TEST=None R=evan@chromium.org Review URL: http://codereview.chromium.org/7550026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@95638 0039d316-1c4b-4281-b951-d872f2087c98
* Remove explicit keyword from multi-argument (w/o default values) constructorsdilmah@chromium.org2011-07-261-10/+9
| | | | | | | | | BUG=None TEST=None Review URL: http://codereview.chromium.org/7477008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@94115 0039d316-1c4b-4281-b951-d872f2087c98
* Remove IPCSyncChannelTest.BadMessagephajdan.jr@chromium.org2011-07-201-60/+0
| | | | | | | | | | | The test was trying to check that a DCHECK is being hit, but it's not really the best thing to do. BUG=62511 Review URL: http://codereview.chromium.org/7457010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@93207 0039d316-1c4b-4281-b951-d872f2087c98
* some cleanup for base/stl_utildilmah@chromium.org2011-07-192-2/+2
| | | | | | | | | | | | | removed unused/irrelevant functions removed irrelevant comments Moved stl_util-inl.h => stl_util.h BUG=None TEST=None Review URL: http://codereview.chromium.org/7342047 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@93110 0039d316-1c4b-4281-b951-d872f2087c98
* Add COMPONENT_BUILD global define. darin@chromium.org2011-07-131-0/+1
| | | | | | | | | | | | | | | | | | | | | This avoids the need to define FOO_DLL macros for each project that we wish to optionally build as a DLL (when component=="shared_library"). This in turn means that we do not need direct_dependent_settings to define FOO_DLL, and that means that we don't need to update projects to convert transitive dependencies into explicit dependencies. This makes the component build more consistent with the static build. An alternative would be to use all_dependent_settings, but I feel that the global approach is simpler as it creates less repetition in each target definition for components. A side-effect of this change is that I needed to make base_nacl_win64 be a shared_library in the component build. R=rvargas,bradnelson,evan Review URL: http://codereview.chromium.org/7344022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92409 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Add COMPONENT_BUILD global define. "yurys@chromium.org2011-07-131-1/+0
| | | | | | | | | | | | | The change broke compilation on Linux Builder (dbg)(shared): http://build.chromium.org/p/chromium/builders/Linux%20Builder%20%28dbg%29%28shared%29/builds/3365/steps/compile/logs/stdio TBR=darin BUG=None TEST=None Review URL: http://codereview.chromium.org/7352014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92329 0039d316-1c4b-4281-b951-d872f2087c98
* Add COMPONENT_BUILD global define. darin@chromium.org2011-07-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | This avoids the need to define FOO_DLL macros for each project that we wish to optionally build as a DLL (when component=="shared_library"). This in turn means that we do not need direct_dependent_settings to define FOO_DLL, and that means that we don't need to update projects to convert transitive dependencies into explicit dependencies. This makes the component build more consistent with the static build. An alternative would be to use all_dependent_settings, but I feel that the global approach is simpler as it creates less repetition in each target definition for components. A side-effect of this change is that I needed to make base_nacl_win64 be a shared_library in the component build. R=rvargas,bradnelson Review URL: http://codereview.chromium.org/7344022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92325 0039d316-1c4b-4281-b951-d872f2087c98
* Move base/values.h into the base namespace. This includes a cros DEPS rolldmazzoni@chromium.org2011-07-121-6/+6
| | | | | | | | | | with a minor change to that code since libcros also uses base/values.h. BUG=88666 TEST=none Review URL: http://codereview.chromium.org/7259019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92208 0039d316-1c4b-4281-b951-d872f2087c98
* Remove the comments setting emands and vim tab width and expansion variables.tony@chromium.org2011-07-112-12/+0
| | | | | | | | | | | | | | | | | These were added in r28089 (http://codereview.chromium.org/256059) but are unnecessary bloat for everyone to carry around, even those that don't use emacs or vim. In an earlier change, I added editor config files in src/tools/emacs/ and src/tools/vim/ so users of the appropriate editor can source those instead. BUG=none TEST=none Review URL: http://codereview.chromium.org/7310019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92046 0039d316-1c4b-4281-b951-d872f2087c98
* Add tsepez to ipc/OWNERS.thakis@chromium.org2011-07-081-0/+1
| | | | | | | | | | | | Requested by jam. BUG=none TEST=none Review URL: http://codereview.chromium.org/7330011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@91870 0039d316-1c4b-4281-b951-d872f2087c98
* Add jam to ipc/OWNERSthakis@chromium.org2011-07-061-0/+1
| | | | | | | | | | BUG=none TEST=none TBR=darin Review URL: http://codereview.chromium.org/7312012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@91594 0039d316-1c4b-4281-b951-d872f2087c98
* Add ipc/OWNERSthakis@chromium.org2011-07-031-0/+5
| | | | | | | | | | | | | | | I looked through some of the changes in the directory and who ok'd them (agl, dmac, jeremy), and threw in cpu because I think he wrote this originally and darin because he ok'd creation of this directory. BUG=88315 TEST=none Review URL: http://codereview.chromium.org/7304015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@91453 0039d316-1c4b-4281-b951-d872f2087c98
* MediaStreamDispatcher perkj@google.com2011-06-281-0/+1
| | | | | | | | | | | | | This is the second Chromium patch needed to support media streams http://www.whatwg.org/specs/web-apps/current-work/multipage/dnd.html#video-conferencing-and-peer-to-peer-communication. The first patch is here http://codereview.chromium.org/7192007/. The patch contain types needed in both the render and browser process and MediaStreamDispatcher that is used for sending request from the render process to the browser process for granting a webpage access to audio input and video capture devices. BUG=none TEST=none Review URL: http://codereview.chromium.org/7184010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@90752 0039d316-1c4b-4281-b951-d872f2087c98
* Patch for Solaris support, mostly ifdefs and header files, plus adds ↵chromium@hybridsource.org2011-06-251-0/+2
| | | | | | | | | | | libevent configuration. BUG=30101 TEST=compiles Review URL: http://codereview.chromium.org/7238021 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@90494 0039d316-1c4b-4281-b951-d872f2087c98
* Fix to bug 75303abeera@google.com2011-06-241-1/+4
| | | | | | | | | | Makes the sun_path an absolute path("/tmp/pipe_name") to allow IPC between processes with different working directories BUG=75303 TEST=NONE Review URL: http://codereview.chromium.org/7167017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@90400 0039d316-1c4b-4281-b951-d872f2087c98
* Use vector_as_array() in ipc/ipc_channel_posix.cctzik@chromium.org2011-06-221-1/+2
| | | | | | | | | | BUG=65151 TEST=None Review URL: http://codereview.chromium.org/7216030 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@89986 0039d316-1c4b-4281-b951-d872f2087c98
* Coverity: Initialize member variables.jhawkins@chromium.org2011-06-211-0/+2
| | | | | | | | | | | | CID=16452 BUG=none TEST=none R=thestig@chromium.org Review URL: http://codereview.chromium.org/7217017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@89917 0039d316-1c4b-4281-b951-d872f2087c98
* Remove msvs_guids from ipc, media, net, ppapi, printing, sandbox,tony@chromium.org2011-06-161-1/+0
| | | | | | | | | | sdch, skia, and testing. BUG=28727 Review URL: http://codereview.chromium.org/7165009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@89369 0039d316-1c4b-4281-b951-d872f2087c98
* Hooking MHTML generation to the browser.jcivelli@chromium.org2011-06-143-1/+51
| | | | | | | | | | | | | | This CL adds a class that can be used to generate MHTML for the current page of a tab. It is not yet surfaced in the UI. BUG=None TEST=Run the browser tests. Review URL: http://codereview.chromium.org/7044095 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@89047 0039d316-1c4b-4281-b951-d872f2087c98
* Move UtilityProcessHost to content and move the message sending/dispatching ↵jam@chromium.org2011-06-091-0/+1
| | | | | | | | | to the clients. This allows the content layer to use the class. BUG=76697 Review URL: http://codereview.chromium.org/6995095 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@88586 0039d316-1c4b-4281-b951-d872f2087c98
* Disable IPCSyncChannelTest.BadMessage on windows. It crashes occasionally.kkania@chromium.org2011-06-031-1/+8
| | | | | | | | | BUG=62511 TEST=none TBR=dhollowa git-svn-id: svn://svn.chromium.org/chrome/trunk/src@87893 0039d316-1c4b-4281-b951-d872f2087c98
* More POSIX support for Chromium, consisting mostly of broadening ifdefs. Thistony@chromium.org2011-06-021-2/+2
| | | | | | | | | | | | | | patch cuts across modules, as there's only a handful necessary for each, with the most in chrome/test/. ALSA is enabled on FreeBSD and Solaris, as libasound has been ported to those two platforms, and I moved resolv.h in host_resolver_proc.cc, because it depends on headers from sys_addrinfo.h on FreeBSD. Patch by ruben (chromium@hybridsource.org) Review URL: http://codereview.chromium.org/6976055 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@87641 0039d316-1c4b-4281-b951-d872f2087c98
* Virtual destructors should have virtual keyword.hans@chromium.org2011-05-255-9/+8
| | | | | | | | | | | | | | | | | Make sure user-declared virtual destructors always have the virtual keyword. The Clang style-check plugin will check for this soon. No functionality change: virtual is only added to destructors that are already implicitly virtual. Also fix a couple of in-line destructor definitions. BUG=83408 TEST=none Review URL: http://codereview.chromium.org/7064033 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86587 0039d316-1c4b-4281-b951-d872f2087c98
* Final gyp patch to make use of the new cross-platform POSIX defines ↵tony@chromium.org2011-05-231-3/+3
| | | | | | | | toolkit_uses_gtk, os_posix, and use_x11. For lists of source files that use a mix of POSIX and Gtk APIs, toolkit_uses_gtk was given precedence. Solaris was made to use ALSA also, as libasound has been ported to FreeBSD and Solaris as a wrapper around the native OSS. Review URL: http://codereview.chromium.org/7055003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86352 0039d316-1c4b-4281-b951-d872f2087c98
* Globally replace <(library) with static_libraryevan@chromium.org2011-05-192-3/+3
| | | | | | | | | | | We provided <(library) as a variable to support a peculiar build configuration on Linux. We no longer support that build configuration, so we can simplify this code to no longer use a variable. Review URL: http://codereview.chromium.org/7051014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86004 0039d316-1c4b-4281-b951-d872f2087c98
* IPC: Increase MAX_DESCRIPTORS_PER_MESSAGEmseaborn@chromium.org2011-05-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | This fixes the loading of Native Client's integrated runtime (IRT) library on Mac, because we need to send 5 descriptors in NaCl's startup IPC message on Mac. I am being conservative in only increasing MAX_DESCRIPTORS_PER_MESSAGE by 1 because it carries a storage cost (in Channel::ChannelImpl::input_cmsg_buf_) which is multiplied by the number of messages that can fit into Channel::kReadBufferSize, and the storage is allocated for the lifetime of the Channel. Note that I am not increasing the size of input_cmsg_buf_ under "#if defined(OS_MACOSX)" in ipc_channel_posix.h because it is already too small in the general case (see http://crbug.com/82829), but NaCl does not exercise this general case. BUG=http://code.google.com/p/nativeclient/issues/detail?id=1804 TEST=NaCl's "run_ppapi_core_browser_test irt=1" when run against Chromium Review URL: http://codereview.chromium.org/7010015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85617 0039d316-1c4b-4281-b951-d872f2087c98
* Removing 'using namespace' style violations in src/ipc/kushi.p@gmail.com2011-05-131-5/+8
| | | | | | | | | | BUG=82078 TEST=None Review URL: http://codereview.chromium.org/6973055 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85340 0039d316-1c4b-4281-b951-d872f2087c98
* Enhance the comment about IPC_USES_READWRITE. I was confused and thought thatbrettw@chromium.org2011-05-131-2/+9
| | | | | | | | | messages containing file descriptors would be sent over the other channel, rather than just the file descriptors. This is important because it preserves the message ordering. Review URL: http://codereview.chromium.org/7021002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85300 0039d316-1c4b-4281-b951-d872f2087c98
* iwyu: Include stringprintf.h where appropriate, part 1.jhawkins@chromium.org2011-05-101-0/+1
| | | | | | | | | | | BUG=82098 TEST=none R=thakis@chromium.org Review URL: http://codereview.chromium.org/6997006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84754 0039d316-1c4b-4281-b951-d872f2087c98
* Remove non-default DACL on the Pipe creationcpu@chromium.org2011-05-061-96/+10
| | | | | | | | | | | | | | -Not needed -Interferes with sandbox propper brokering -Faster pipe creation Some other small cleaning done as well. BUG=none TEST= sufficient coverage with existing tests, chrome works. Review URL: http://codereview.chromium.org/6927070 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84461 0039d316-1c4b-4281-b951-d872f2087c98
* IPC outgoing message filters interpose yourself in a message stream. ↵tsepez@chromium.org2011-05-042-2/+26
| | | | | | | | Minimally invasive baseline for building IPC tests to abuse browser along the lines of a compromised renderer. Review URL: http://codereview.chromium.org/6711024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84076 0039d316-1c4b-4281-b951-d872f2087c98
* Switch IPC::ChannelProxy to use MessageLoopProxy instead of MessageLoop. ↵jam@chromium.org2011-05-026-30/+35
| | | | | | | | This allows us to remove usage of the IOThread object, and generally makes IPC::ChannelProxy more robust for future uses. Review URL: http://codereview.chromium.org/6901146 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83741 0039d316-1c4b-4281-b951-d872f2087c98
* [Mac] Implement the system dictionary popup by implementing NSTextInput methods.rsesek@chromium.org2011-05-021-0/+1
| | | | | | | | | | | | | | | | | This is a two-sided patch; the Chromium side is plumbing to marshall data from the renderer to the system APIs. Note that just hitting Cmd+Ctrl+D usually does not bring up the popup. I think this may be an Apple bug, but I have not yet found a work-around. BUG=17951,37715,47141 TEST=Hold Cmd+Ctrl+D on a web page and mouse around. The dictionary popup should follow the mouse and show the definition of the current word. TEST=In a text area, the dictionary popup should work only if the text area has focus. R=avi,suzhe,jam Review URL: http://codereview.chromium.org/6289009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83723 0039d316-1c4b-4281-b951-d872f2087c98
* Improving logging in /app, /base, /crypto and /ipc. Updating plain DCHECK() ↵kushi.p@gmail.com2011-04-283-29/+67
| | | | | | | | | | | usages for DCHECK_EQ/LE/GE() equivalents. BUG=58409 TEST=None Review URL: http://codereview.chromium.org/6880166 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83362 0039d316-1c4b-4281-b951-d872f2087c98
* Base: Adjust dependencies to build with base.dllrvargas@google.com2011-04-281-1/+2
| | | | | | | | BUG=76996 TEST=none Review URL: http://codereview.chromium.org/6883205 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83269 0039d316-1c4b-4281-b951-d872f2087c98
* Remove unused member from POSIX implementation of ChannelImpl.cbentzel@chromium.org2011-04-212-4/+1
| | | | | | | | | | BUG=None TEST=Compiles Review URL: http://codereview.chromium.org/6873119 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82485 0039d316-1c4b-4281-b951-d872f2087c98
* Make icon_messages use the IPC macros for defining the structs and the ↵jam@chromium.org2011-04-181-0/+1
| | | | | | | | serialization code, and move the icon messages there. Also get rid of friend class in RenderView that's not needed anymore. Review URL: http://codereview.chromium.org/6883020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81999 0039d316-1c4b-4281-b951-d872f2087c98
* Replacing outdated DCHECK(a == b) with DCHECK_EQ(a, b).david.mike.futcher@gmail.com2011-04-181-5/+5
| | | | | | | | | | | | | This is my first attempt at contributing, so please tell me where I'm going wrong. BUG=58409 TEST= Review URL: http://codereview.chromium.org/6851016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81988 0039d316-1c4b-4281-b951-d872f2087c98