summaryrefslogtreecommitdiffstats
path: root/dbus/file_descriptor.cc
Commit message (Collapse)AuthorAgeFilesLines
* Re-land Move ScopedFileDescriptor to dbus/file_descriptor.hcmasone2015-04-271-0/+9
| | | | | | | | | | | | | | | | | | | | ScopedFileDescriptor was initially introduced to facilitate the management of a 'lifeline' FD used when asking permission_broker to open a port in the device's firewall on CrOS. It's actually a scoped wrapper around DBus::FileDescriptor, not a platform file descriptor. I would like to use it to facilitate some other similar functionality in which I create a pipe and pass one end over DBus, so it seems like a good idea to move ScopedFileDescriptor into the dbus library directly. This reverts commit ee9dc849ffa2df2820381c31d5ba8200774d287a. BUG=chromium:481340 TEST=FirewallHole unit tests still pass TBR=stevenjb, reillyg, keybuk Review URL: https://codereview.chromium.org/1108083003 Cr-Commit-Position: refs/heads/master@{#327141}
* Revert of Move ScopedFileDescriptor to dbus/file_descriptor.h (patchset #1 ↵spang2015-04-271-9/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | id:1 of https://codereview.chromium.org/1090243003/) Reason for revert: Breaks shared_library build with broken exports: ./../dbus/dbus_export.h:20:65: error: ignoring attributes applied to class type 'scoped_ptr<dbus::FileDescriptor, dbus::FileDescriptor::Deleter>' outside of definition [-Werror=attributes] #define CHROME_DBUS_EXPORT __attribute__((visibility("default"))) ^ ../../dbus/file_descriptor.h:81:57: note: in expansion of macro 'CHROME_DBUS_EXPORT' scoped_ptr<FileDescriptor, FileDescriptor::Deleter> CHROME_DBUS_EXPORT; Original issue's description: > Move ScopedFileDescriptor to dbus/file_descriptor.h > > ScopedFileDescriptor was initially introduced to facilitate the > management of a 'lifeline' FD used when asking permission_broker to > open a port in the device's firewall on CrOS. It's actually a scoped > wrapper around DBus::FileDescriptor, not a platform file descriptor. I > would like to use it to facilitate some other similar functionality in > which I create a pipe and pass one end over DBus, so it seems like a > good idea to move ScopedFileDescriptor into the dbus library directly. > > BUG=chromium:481340 > TEST=FirewallHole unit tests still pass > STATUS=Fixed > R=keybuk, reillyg, stevenjb > > Committed: https://crrev.com/b44fbaabbe9f91e63ad8aa164609a6b31e0de57e > Cr-Commit-Position: refs/heads/master@{#327089} TBR=keybuk@chromium.org,reillyg@chromium.org,stevenjb@chromium.org,cmasone@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=chromium:481340 Review URL: https://codereview.chromium.org/1108893003 Cr-Commit-Position: refs/heads/master@{#327103}
* Move ScopedFileDescriptor to dbus/file_descriptor.hcmasone2015-04-271-0/+9
| | | | | | | | | | | | | | | | | | | ScopedFileDescriptor was initially introduced to facilitate the management of a 'lifeline' FD used when asking permission_broker to open a port in the device's firewall on CrOS. It's actually a scoped wrapper around DBus::FileDescriptor, not a platform file descriptor. I would like to use it to facilitate some other similar functionality in which I create a pipe and pass one end over DBus, so it seems like a good idea to move ScopedFileDescriptor into the dbus library directly. BUG=chromium:481340 TEST=FirewallHole unit tests still pass STATUS=Fixed R=keybuk, reillyg, stevenjb Review URL: https://codereview.chromium.org/1090243003 Cr-Commit-Position: refs/heads/master@{#327089}
* Remove PlatformFile from dbus/file_descriptorrvargas@chromium.org2014-06-071-4/+6
| | | | | | | | BUG=322664 Review URL: https://codereview.chromium.org/307423005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275563 0039d316-1c4b-4281-b951-d872f2087c98
* dbus: revamp fd passing support for i/o restrictionssleffler@chromium.org2012-05-101-0/+18
| | | | | | | | | | | | | | Encapsulate file descriptor validity checking and status in the companion FileDescriptor class so callers can do descriptor checking in a context where i/o is allowed. Update the debug daemon client support to validate the pipe descriptors in a worker thread so it is not done on the UI thread. BUG=126142 TEST=new unit tests + collect trace data on chrome os and verify no assert is triggered Review URL: https://chromiumcodereview.appspot.com/10382021 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@136331 0039d316-1c4b-4281-b951-d872f2087c98
* dbus: add support for passing file descriptorssleffler@chromium.org2012-03-301-0/+15
Add support for passing file descriptors in messages. BUG=chromium-os:27809 TEST=run unit tests Change-Id: I48e52e52ea1e1a4b96bb0dbec7242337e5871510 Review URL: http://codereview.chromium.org/9700072 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@129801 0039d316-1c4b-4281-b951-d872f2087c98