summaryrefslogtreecommitdiffstats
path: root/base/shared_memory_posix.cc
Commit message (Collapse)AuthorAgeFilesLines
* Move shared_memory into base/memory subdirectory.brettw@chromium.org2013-03-291-382/+0
| | | | | | | | | | This leaves a forwarding header in place so all calling code can be updated asynchronously. BUG= Review URL: https://codereview.chromium.org/13044024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@191392 0039d316-1c4b-4281-b951-d872f2087c98
* Fix Android-specific shmem size code.aelias@chromium.org2013-03-291-10/+4
| | | | | | | | | | | | | | | | | | | | | In the past, this OS_ANDROID block assigned a value to created_size_ (which appears not to have been used for anything), whereas mapped_size_ used the cross-platform codepath. In r191098 jschuh@ disabled the normal assignment of mapped_size_ on Android and made this old code set the value of mapped_size_. This Android code block was there to set "bytes" in when Map is called with a size argument of 0. So after r191098, mapped_size_ was never set when the argument was nonzero. Bring back the mapped_size_ setting and clean up the Android block. NOTRY=true BUG=224646 Review URL: https://chromiumcodereview.appspot.com/13133004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@191250 0039d316-1c4b-4281-b951-d872f2087c98
* Make SharedMemory track the size that was actually mappedjschuh@chromium.org2013-03-281-8/+10
| | | | | | | | | | | In the process I also had to fix several dependencies, and some major issues in transport DIBs. BUG=60819 Review URL: https://chromiumcodereview.appspot.com/12537014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@191098 0039d316-1c4b-4281-b951-d872f2087c98
* Remove/simplify the POSIX SharedMemory::Create() a bit.viettrungluu@chromium.org2013-01-311-10/+7
| | | | | | | | | | | | | | | | | | | This gets called on the IO thread. On Mac, operations done on a real (disk-backed) filesystem (not a RAM/swap-backed tmpfs), and are slow: - Use unlink() directly instead of file_util::Delete(). This saves a stat (which is used to determine if the target is a directory or not). - Don't bother doing the fseeko(). This is unneeded, since mmap() takes an absolute offset. (ftruncate() will grow files both on Linux and Mac. On non-XSI POSIX systems where this is not the case, the seek alone isn't sufficient to grow the file in any case.) Both these show up on a profile of a big session restore on Mac (though unfortunately the bulk of the time is spent in mkstemp() and its internal file open). (There's still a redundant stat, perhaps to be taken care of later.) Review URL: https://chromiumcodereview.appspot.com/12089054 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@179941 0039d316-1c4b-4281-b951-d872f2087c98
* Added SharedMemory::MapFrom.vitalybuka@chromium.org2013-01-161-4/+4
| | | | | | | | | | Fragmentation of address space may prevents process from allocate entire block of shared memory. Particularly in attached bug browser process can't allocate 250Mb to accept data from renderer Mapping smaller blocks is workaround. BUG=93202 Review URL: https://chromiumcodereview.appspot.com/11876037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@177109 0039d316-1c4b-4281-b951-d872f2087c98
* The correct type for the size of a chunk of memory is size_t.cevans@chromium.org2013-01-101-3/+9
| | | | | | | | | | | | | | | | | | By using uint32, we have bugs on 64-bit platforms: callers passing in a size_t, will have their size truncated, potentially allocating a smaller chunk than requested. There are a few places this happens, including on the receiving ends of IPCs(!) However, coversely, other callers of the API might directly assign the memory chunk's length to uint32, leading to a different possible truncation problem. This is guaraded against by limiting operations internally to std::numeric_limits<uint32_t> in size for now. There's some minor cascade effects that make the CL look larger than it is. BUG=164678 Review URL: https://codereview.chromium.org/11446048 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@175987 0039d316-1c4b-4281-b951-d872f2087c98
* Make ShareToProcess return false when dup() fails. This matches the behaviordarin@chromium.org2012-11-201-1/+5
| | | | | | | | | | | of the function on Windows. R=mark@chromium.org BUG=160401 Review URL: https://chromiumcodereview.appspot.com/11416078 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@168751 0039d316-1c4b-4281-b951-d872f2087c98
* Advertise a minimum alignment for SharedMemory::Map().dalecurtis@chromium.org2012-08-181-2/+5
| | | | | | | | | | | | | | | | | No real changes, just adds a DCHECK() and unit test for a minimum alignment that callers can count on from Map(). Map() is already returning addresses which are aligned to the platform page size. Necessary for a media use case in which a wrapped shared memory object is passed around and is expected to have a certain alignment. BUG=none TEST=unittests, try bots. Review URL: https://chromiumcodereview.appspot.com/10827400 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@152218 0039d316-1c4b-4281-b951-d872f2087c98
* mmap returns -1 on failure and in the posix implementation of SharedMemory, ↵raymes@chromium.org2012-04-231-3/+4
| | | | | | | | | | | | | | this was setting memory_ to -1. However the interface for SharedMemory specifies that memory_ should be NULL if it is unmapped. Furthermore there was DCHECK included to check the success of mmap, but I feel this is incorrect because we are returning the success (e.g. other platform implementations don't do this). The caller can DCHECK if they need. We could change this to a LOG call. BUG=None TEST=out/Debug/base_unittests Review URL: http://codereview.chromium.org/10174007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@133516 0039d316-1c4b-4281-b951-d872f2087c98
* Improve SharedMemory::Lock on Posix and reenable StatsTableTest.MultipleThreadsvandebo@chromium.org2012-02-251-1/+7
| | | | | | | | | | BUG=10611 TEST=NONE Review URL: http://codereview.chromium.org/9463018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123647 0039d316-1c4b-4281-b951-d872f2087c98
* Change code in base (primarily unit tests) to use Sleep(TimeDelta).tedvessenes@gmail.com2011-12-311-1/+1
| | | | | | | | | | BUG=108171 TEST= Review URL: http://codereview.chromium.org/9055001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@116065 0039d316-1c4b-4281-b951-d872f2087c98
* Adaptively use temp dir instead of /dev/shm for executable shmem file on Linuxmcgrathr@chromium.org2011-12-061-2/+2
| | | | | | | | | | | | | | | | | On some Linux systems, files from /dev/shm cannot have PROT_EXEC applied to their mappings. This depends on picayune setup details that vary between distributions and kernels and could vary between installations. So just use an empirical test of whether it works or not, and fall back to using generic temporary space instead of /dev/shm for the executable case if needed. BUG= http://code.google.com/p/chromium/issues/detail?id=103377 TEST= SharedMemory.AnonymousExecutable with /dev/shm mounted noexec R=mark@chromium.org Review URL: http://codereview.chromium.org/8800025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@113228 0039d316-1c4b-4281-b951-d872f2087c98
* Give base::SharedMemory::CreateAnonymous an executable flagmcgrathr@chromium.org2011-12-011-15/+10
| | | | | | | | | | | | | | | | | | | | | NaCl on Mac and Linux needs to create a shared memory object that it can later make executable with mprotect. Express this need in the interface it uses. Add a test that pages mapped from such an object can later be passed to mprotect with PROT_EXEC. This lays the groundwork for a later change that will sometimes use a different method to allocate an object on Linux when it needs to be executable. On some Linux distributions, shm_open yields objects whose mappings cannot be made executable. BUG= http://code.google.com/p/chromium/issues/detail?id=103377 TEST= SharedMemory.AnonymousExecutable R=mark@chromium.org,jam@chromium.org,amit@chromium.org,ben@chromium.org Review URL: http://codereview.chromium.org/8585002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@112570 0039d316-1c4b-4281-b951-d872f2087c98
* Replace most LOG/CHECK statements with DLOG/DCHECK statements in base.brettw@chromium.org2011-10-261-2/+2
| | | | | | | | | | | [ Reland of 107042 http://codereview.chromium.org/8368009 ] I tried hard not to change CHECKs that had side effects. I kept fatal checks that seemed security or debugging-info (in crash reports) sensitive, and ones that seems particularly well-conceived. Review URL: http://codereview.chromium.org/8341026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@107434 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 107042 - Replace most LOG/CHECK statements with DLOG/DCHECK ↵brettw@chromium.org2011-10-251-2/+2
| | | | | | | | | | | | | | statements in base. I tried hard not to change CHECKs that had side effects. I kept fatal checks that seemed security or debugging-info (in crash reports) sensitive, and ones that seems particularly well-conceived. Review URL: http://codereview.chromium.org/8368009 TBR=brettw@chromium.org Review URL: http://codereview.chromium.org/8351025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@107051 0039d316-1c4b-4281-b951-d872f2087c98
* Replace most LOG/CHECK statements with DLOG/DCHECK statements in base.brettw@chromium.org2011-10-251-2/+2
| | | | | | | | | I tried hard not to change CHECKs that had side effects. I kept fatal checks that seemed security or debugging-info (in crash reports) sensitive, and ones that seems particularly well-conceived. Review URL: http://codereview.chromium.org/8368009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@107042 0039d316-1c4b-4281-b951-d872f2087c98
* Upstream android debug and log related filesmichaelbai@google.com2011-07-071-1/+1
| | | | | | | | | BUG= TEST= Review URL: http://codereview.chromium.org/7238012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@91748 0039d316-1c4b-4281-b951-d872f2087c98
* Coverity fixes CID=15870,13529 Check pointer before assign, resource leak.gbillock@chromium.org2011-06-271-3/+9
| | | | | | Review URL: http://codereview.chromium.org/7222010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@90599 0039d316-1c4b-4281-b951-d872f2087c98
* Upstream android file related code.michaelbai@google.com2011-06-211-0/+28
| | | | | | | | | | | Implemented file related features BUG=None TEST=None Review URL: http://codereview.chromium.org/7184032 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@89914 0039d316-1c4b-4281-b951-d872f2087c98
* Update DCHECK() usage to utilize the more expressive debugging functions.kushi.p@gmail.com2011-04-221-1/+1
| | | | | | | | BUG=58409 Review URL: http://codereview.chromium.org/6891008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82639 0039d316-1c4b-4281-b951-d872f2087c98
* Use the real Mac browser app's bundle identifier everywhere that a basemark@chromium.org2011-04-221-1/+14
| | | | | | | | | | | | | | | | | | | | | bundle identifier is needed on the Mac. This means that everything will use up using org.chromium.Chromium, com.google.Chrome, or com.google.Chrome.canary when it's important to get the base bundle identifier. .helper and .framework will not be appended. Note, however, that things that run inside the helper and use CFPreferences or NSUserDefaults will continue to write their defaults as org.chromium.Chromium.helper or com.google.Chrome.helper. Mostly this just affects the Flash plug-in's settings for the NSNav open dialog. There is no com.google.Chrome.canary.helper, but that's not expected to be a problem. This change ensures that Chromes, canaries, and Chromiums don't get in each other's way. BUG=79814 TEST=none Review URL: http://codereview.chromium.org/6896003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82626 0039d316-1c4b-4281-b951-d872f2087c98
* Fix problems in src/base:phajdan.jr@chromium.org2011-04-121-1/+1
| | | | | | | | | | | | - de-facto ignored return value of PathService::Get in base_paths_mac.mm - missing EINTR handling in other files I was just reading the code looking for some issues. BUG=none Review URL: http://codereview.chromium.org/6820030 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@81220 0039d316-1c4b-4281-b951-d872f2087c98
* Use DCHECK_GE() where possible in base/. Patch by Kushal Pisavadia (see ↵pkasting@chromium.org2011-03-311-3/+3
| | | | | | | | | http://codereview.chromium.org/6688056/ ), r=me. BUG=58409 TEST=none git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80063 0039d316-1c4b-4281-b951-d872f2087c98
* More DCHECK() updates. A mixture of _EQ and _GE.mhm@chromium.org2011-03-011-4/+4
| | | | | | | | 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
* Dup command-buffer SHM handle before auto-closing.piman@google.com2011-02-231-2/+4
| | | | | | | | | | | This also adds error logging to the various places we close file descriptors, to help diagnosing future similar issues. BUG=none TEST=Pepper Flash + youtube in oop with --enable-accelerated-plugins Review URL: http://codereview.chromium.org/6549037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@75792 0039d316-1c4b-4281-b951-d872f2087c98
* Order function definitions in base/ according to the header.erg@google.com2011-01-111-63/+62
| | | | | | | | | BUG=68682 TEST=compiles Review URL: http://codereview.chromium.org/6085015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70975 0039d316-1c4b-4281-b951-d872f2087c98
* Move base/thread.h to base/threading, fix up callers to use the new location.brettw@chromium.org2011-01-011-1/+1
| | | | | | | | TEST=it compiles BUG=none Review URL: http://codereview.chromium.org/6028009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70345 0039d316-1c4b-4281-b951-d872f2087c98
* Move platform_thread to base/threading and put in the base namespace. I left abrettw@chromium.org2010-12-311-2/+2
| | | | | | | | | | | stub and "using" declarations in the old location to avoid having to change the entire project at once. TEST=it compiles BUG=none Review URL: http://codereview.chromium.org/6001010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70342 0039d316-1c4b-4281-b951-d872f2087c98
* While there are all sorts of reasons for "/dev/shm" to be inaccessible,markus@chromium.org2010-11-011-1/+1
| | | | | | | | | | | | | and "chmod" might or might not actually fix the problem, we should never give advice that actually introduces more problems. Changing permissions to 777 is bad, as it drops the sticky bit. Instead, the instructions should say 1777. BUG=none TEST=none Review URL: http://codereview.chromium.org/4245001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@64673 0039d316-1c4b-4281-b951-d872f2087c98
* Fix up SharedMemory implementation so that it is more equivalent on Windows ↵dmaclach@chromium.org2010-10-271-104/+100
| | | | | | | | | | | | | vs Posix and enforces exclusive creates. Clean up some naming to make it clearer what size you are getting by changing max_size to created_size. BUG=NONE TEST=BUILD Review URL: http://codereview.chromium.org/4034006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@64097 0039d316-1c4b-4281-b951-d872f2087c98
* Thread IO safety: annotate file_util, and block IO thread from doing IOevan@chromium.org2010-10-231-0/+6
| | | | | | | | | | | | | | | - Mark functions in file_util_posix as requiring permission to perform disk actions. - Mark the IO thread as disallowed from performing disk actions. - Temporarily work around the protections in places where we currently have bugs. BUG=59847,59849,60207,60211,60394 TEST=no dchecks in debug builds Review URL: http://codereview.chromium.org/3872002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63636 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 63600 - Thread IO safety: annotate file_util, and block IO thread ↵isherman@chromium.org2010-10-231-6/+0
| | | | | | | | | | | | | | | | | | | | | | from doing IO Reverting because this breaks the ChromiumOS (dbg) builder. - Mark functions in file_util_posix as requiring permission to perform disk actions. - Mark the IO thread as disallowed from performing disk actions. - Temporarily work around the protections in places where we currently have bugs. BUG=59847,59849,60207,60211 TEST=no dchecks in debug builds Review URL: http://codereview.chromium.org/3872002 TBR=evan@chromium.org Review URL: http://codereview.chromium.org/3983005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63630 0039d316-1c4b-4281-b951-d872f2087c98
* Thread IO safety: annotate file_util, and block IO thread from doing IOevan@chromium.org2010-10-231-0/+6
| | | | | | | | | | | | | | | - Mark functions in file_util_posix as requiring permission to perform disk actions. - Mark the IO thread as disallowed from performing disk actions. - Temporarily work around the protections in places where we currently have bugs. BUG=59847,59849,60207,60211 TEST=no dchecks in debug builds Review URL: http://codereview.chromium.org/3872002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63600 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Thread IO safety: annotate file_util, and block IO thread from doing IO"evan@chromium.org2010-10-221-6/+0
| | | | | | This reverts commit r63580, build breakage. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63586 0039d316-1c4b-4281-b951-d872f2087c98
* Thread IO safety: annotate file_util, and block IO thread from doing IOevan@chromium.org2010-10-221-0/+6
| | | | | | | | | | | | | | | - Mark functions in file_util_posix as requiring permission to perform disk actions. - Mark the IO thread as disallowed from performing disk actions. - Temporarily work around the protections in places where we currently have bugs. BUG=59847,59849,60207,60211 TEST=no dchecks in debug builds Review URL: http://codereview.chromium.org/3872002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63580 0039d316-1c4b-4281-b951-d872f2087c98
* shared_memory: improve error messages on failure.evan@chromium.org2010-09-291-4/+11
| | | | | | | | | | | | | | | | | Be careful to leave errno untouched if the file open fails, so that the latter logging statements that print errno will print the right message. Also format the logging text such that the perror-like output (appending text like ": Permission denied") makes more sense. Previously we'd end up printing text like Try [...] to fix.: Permission denied BUG=57305 TEST=shared_memory_unittest should still pass Review URL: http://codereview.chromium.org/3517003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60986 0039d316-1c4b-4281-b951-d872f2087c98
* shared_memory: remove wstrings, fix callers.evan@chromium.org2010-09-291-12/+11
| | | | | | | | | BUG=23581 TEST=compiles Review URL: http://codereview.chromium.org/3555002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60985 0039d316-1c4b-4281-b951-d872f2087c98
* Header cleanup in base.brettw@chromium.org2010-08-171-3/+3
| | | | | | | | | | | | | | This makes uses of StringPrintf and friends use the base namespace and include stringprintf.h explicitly. This also removes a bunch of unnecessary string_util includes (which exposed a few other errors like people forgetting to include <vector>. TEST=it compiles BUG=none Review URL: http://codereview.chromium.org/3119022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@56446 0039d316-1c4b-4281-b951-d872f2087c98
* Valid FDs are >= 0 (> -1), not >= -1.mark@chromium.org2010-05-051-1/+1
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/1937008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@46478 0039d316-1c4b-4281-b951-d872f2087c98
* linux: make shm opening failure fatalevan@chromium.org2010-03-291-3/+5
| | | | | | | | | | | | | | We should eventually add some recovery code path, but right now it's completely broken (see bug) and this is the quicker fix. FATAL logs pop up a dialog explaining what went wrong, too, so this will help users who don't look at the console output. BUG=39710 TEST=sudo chmod o-w /dev/shm; verify you get a dialog that yells at you at startup Review URL: http://codereview.chromium.org/1545003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42973 0039d316-1c4b-4281-b951-d872f2087c98
* Make SharedMemory use uint32 instead of size_t. This removes the remaining ↵jam@chromium.org2010-02-161-4/+4
| | | | | | | | size_t's from the IPC code. Review URL: http://codereview.chromium.org/581001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39164 0039d316-1c4b-4281-b951-d872f2087c98
* linux: provide a hint to people with misconfigured shmevan@chromium.org2010-01-081-1/+6
| | | | | | | | BUG=24213 Review URL: http://codereview.chromium.org/539003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35838 0039d316-1c4b-4281-b951-d872f2087c98
* Don't do work in the SharedIOBuffer constructor; use an Init method instead. ↵hawk@chromium.org2009-11-201-4/+2
| | | | | | | | | | | | This eliminates instances of allocated-but-invalid SharedIOBuffers. Also clean up some CHECKs and TODOs associated with the bug. The upshot is that we no longer crash in AsyncResourceHandler::OnResponseCompleted() when we can't allocate shared memory. We now crash (properly, I believe) in the renderer process if the shared memory that failed to allocate was the TransportDIB, since the renderer can't communicate with the browser without it. BUG=16371 TEST=none Review URL: http://codereview.chromium.org/391009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@32701 0039d316-1c4b-4281-b951-d872f2087c98
* Add a CHECK() around the SharedMemory ftruncate() call to finger it as a ↵hawk@chromium.org2009-10-291-2/+4
| | | | | | | | | | crash culprit. BUG=16371 TEST=Check the crash logs to see if this CHECK() supplants the CHECK() failure in AsyncResourceHandler::OnWillRead() Review URL: http://codereview.chromium.org/347012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30530 0039d316-1c4b-4281-b951-d872f2087c98
* Eliminate all uses of strerror() in code that uses src/base. strerror() is ↵tschmelcher@chromium.org2009-10-131-3/+3
| | | | | | | | | | | inherently unsafe in multi-threaded apps because it stores the string in a global buffer. It should never be used. If you want to log an error, use PLOG and friends, or if that's too high-level then use safe_strerror(). TEST=built on Linux in 32-bit and 64-bit mode; ran base_unittests in each case; ran Chromium itself in each case; try servers BUG=none Review URL: http://codereview.chromium.org/261055 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28850 0039d316-1c4b-4281-b951-d872f2087c98
* posix: clean up shared memory codeevan@chromium.org2009-09-161-16/+18
| | | | | | | | | | | | | At first I rewrote this to use the shm_*() family of functions, but that doesn't work on OS X. Now I've just cleaned up some bits and added an extra print to help with the below bug. BUG=16371 Review URL: http://codereview.chromium.org/204024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26361 0039d316-1c4b-4281-b951-d872f2087c98
* Use ftruncate() instead of fwrite() to extend files.pinkerton@chromium.org2009-08-261-20/+4
| | | | | | | | BUG=20249 TEST=Browser still works Review URL: http://codereview.chromium.org/174482 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24451 0039d316-1c4b-4281-b951-d872f2087c98
* Handle file descriptor exhaustions a little more gracefully. This prevents ↵stuartmorgan@chromium.org2009-06-121-1/+8
| | | | | | | | | | the browser itself from crashing in Intl2 page cycler tests on the Mac (although the renderer still dies, at least in debug), so that seems like a good idea whatever larger solution we find for the file descriptor issue. TEST=none BUG=none Review URL: http://codereview.chromium.org/125024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18318 0039d316-1c4b-4281-b951-d872f2087c98
* Fix a memory leak in ResourceDispatcherhclam@chromium.org2009-05-181-0/+6
| | | | | | | | | | | | When we delete a ResourceLoaderBridge before OnCompletedRequest is received, bad things happen. There's a lot of leaks at the following points: 1. OnMessageReceived ignores the message. 2. RemovePendingRequest removes it's internal deferred_message_queue. But ViewHostMsg_Resource_DataReceived is not POD. We should also close the shared memory handle inside it. Review URL: http://codereview.chromium.org/115396 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16297 0039d316-1c4b-4281-b951-d872f2087c98
* Remove unused variable from POSIX SharedMemory implementation.thestig@chromium.org2009-04-041-7/+4
| | | | | | Review URL: http://codereview.chromium.org/62027 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@13129 0039d316-1c4b-4281-b951-d872f2087c98