From: | Greg Turner <gmt@×××××.us> | ||
---|---|---|---|
To: | gentoo-portage-dev@l.g.o | ||
Subject: | Re: [gentoo-portage-dev] [PATCH] econf: update configure/config.{sub,guess} atomically to avoid races | ||
Date: | Wed, 18 Dec 2013 02:53:05 | ||
Message-Id: | CA+VB3NSX83OzigHC-6E9fdGV-1fzCtHhCHa6K-L6wD68xcUjFw@mail.gmail.com | ||
In Reply to: | Re: [gentoo-portage-dev] [PATCH] econf: update configure/config.{sub,guess} atomically to avoid races by Alec Warner |
1 | On Tue, Dec 17, 2013 at 5:58 PM, Alec Warner <antarus@g.o> wrote: |
2 | > Sed is already atomic |
3 | > |
4 | > antarus@goats5 /tmp/test $ cat foo |
5 | > Debian Rocks! |
6 | > antarus@goats5 /tmp/test $ strace -e trace=file sed -i -e |
7 | > 's/Debian/Gentoo/g' foo |
8 | [snip] |
9 | > open("foo", O_RDONLY) = 3 |
10 | > open("/proc/filesystems", O_RDONLY) = 4 |
11 | > open("./sedfDxBxl", O_RDWR|O_CREAT|O_EXCL, 0600) = 4 |
12 | > rename("./sedfDxBxl", "foo") = 0 |
13 | |
14 | Nice demonstration! Been wondering about that... |
15 | |
16 | -gmt |
Subject | Author |
---|---|
Re: [gentoo-portage-dev] [PATCH] econf: update configure/config.{sub,guess} atomically to avoid races | Alec Warner <antarus@g.o> |