<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Simple bash locking</title>
	<atom:link href="http://blog.oremj.com/2008/12/02/simple-bash-locking/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.oremj.com/2008/12/02/simple-bash-locking/</link>
	<description>What is Jeremy thinking about?</description>
	<lastBuildDate>Thu, 14 Jan 2010 16:57:12 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
	<item>
		<title>By: cp</title>
		<link>http://blog.oremj.com/2008/12/02/simple-bash-locking/comment-page-1/#comment-6237</link>
		<dc:creator>cp</dc:creator>
		<pubDate>Thu, 14 Jan 2010 16:57:12 +0000</pubDate>
		<guid isPermaLink="false">http://blog.oremj.com/?p=24#comment-6237</guid>
		<description>You can avoid the race condition by using &quot;set -o noclobber&quot;. Like this:
if ! (set -o noclobber; echo &quot;$$&quot; &gt; &quot;/tmp/lock&quot;) 2&gt; /dev/null; then
  echo &quot;locking failed&quot;
  exit 1
fi</description>
		<content:encoded><![CDATA[<p>You can avoid the race condition by using &#8220;set -o noclobber&#8221;. Like this:<br />
if ! (set -o noclobber; echo &#8220;$$&#8221; &gt; &#8220;/tmp/lock&#8221;) 2&gt; /dev/null; then<br />
  echo &#8220;locking failed&#8221;<br />
  exit 1<br />
fi</p>
]]></content:encoded>
	</item>
</channel>
</rss>
