This commit is contained in:
root 2006-08-13 00:49:25 +00:00
parent 4aa2323d37
commit 780d6777d2

View file

@ -15,6 +15,10 @@
*/ */
include_once("../includes/mysql.php"); include_once("../includes/mysql.php");
$lck = fopen('/tmp/GPGlock', 'w');
while(flock($lck, LOCK_EX) < 0)
sleep(rand(100000,200000));
$query = "select * from `gpg` where `crt`=''"; $query = "select * from `gpg` where `crt`=''";
$res = mysql_query($query); $res = mysql_query($query);
while($row = mysql_fetch_assoc($res)) while($row = mysql_fetch_assoc($res))
@ -62,4 +66,7 @@
mysql_query($query); mysql_query($query);
} }
} }
flock($lck, LOCK_UN);
fclose($lck);
?> ?>