This is the mail archive of the
mailing list for the glibc project.
Re: RFC: named anonymous vmas
- From: Christoph Hellwig <hch at infradead dot org>
- To: Rich Felker <dalias at aerifal dot cx>
- Cc: Christoph Hellwig <hch at infradead dot org>, Colin Cross <ccross at google dot com>, lkml <linux-kernel at vger dot kernel dot org>, Linux-MM <linux-mm at kvack dot org>, Android Kernel Team <kernel-team at android dot com>, John Stultz <john dot stultz at linaro dot org>, libc-alpha at sourceware dot org
- Date: Fri, 2 Aug 2013 08:11:41 -0700
- Subject: Re: RFC: named anonymous vmas
- References: <CAMbhsRQU=xrcum+ZUbG3S+JfFUJK_qm_VB96Vz=PpL=vQYhUvg at mail dot gmail dot com> <20130622103158 dot GA16304 at infradead dot org> <CAMbhsRTz246dWPQOburNor2HvrgbN-AWb2jT_AEywtJHFbKWsA at mail dot gmail dot com> <20130801082951 dot GA23563 at infradead dot org> <20130801083608 dot GJ221 at brightrain dot aerifal dot cx>
On Thu, Aug 01, 2013 at 04:36:08AM -0400, Rich Felker wrote:
> I'm not sure what the purpose is. shm_open with a long random filename
> and O_EXCL|O_CREAT, followed immediately by shm_unlink, is just as
> good except in the case where you have a malicious user killing the
> process in between these two operations.
The Android people already have an shm API doesn't leave traces in the
filesystem, and I at least conceptually agree that having an API that
doesn't introduce posisble other access is a good idea. This is the
same reason why the O_TMPFILE API was added in this releases.