aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2014-08-12 20:39:57 -0700
committerfriendica <info@friendica.com>2014-08-12 20:39:57 -0700
commit40667e72ad2d473377b68426f06d95d18ac8585f (patch)
treea66b78f53e649ff954ef87a484c4463ce844bc57
parent50da5bd3896f7dfceec6a60cb27976fbd6c2cea0 (diff)
downloadvolse-hubzilla-40667e72ad2d473377b68426f06d95d18ac8585f.tar.gz
volse-hubzilla-40667e72ad2d473377b68426f06d95d18ac8585f.tar.bz2
volse-hubzilla-40667e72ad2d473377b68426f06d95d18ac8585f.zip
couple of frphoto fixes to work better with the dreamhost process reaper
-rw-r--r--mod/frphotos.php8
-rw-r--r--util/frphotohelper.php1
2 files changed, 8 insertions, 1 deletions
diff --git a/mod/frphotos.php b/mod/frphotos.php
index 943651aa2..8d6197fa3 100644
--- a/mod/frphotos.php
+++ b/mod/frphotos.php
@@ -41,6 +41,14 @@ function frphotos_init(&$a) {
$total = 0;
if(count($j)) {
foreach($j as $jj) {
+
+ $r = q("select uid from photo where resource_id = '%s' and uid = %d limit 1",
+ dbesc($jj),
+ intval($channel['channel_id'])
+ );
+ if($r)
+ continue;
+
$total ++;
proc_run('php','util/frphotohelper.php',$jj, $channel['channel_address'], urlencode($fr_server));
sleep(3);
diff --git a/util/frphotohelper.php b/util/frphotohelper.php
index aacfac3e5..3ff3ae465 100644
--- a/util/frphotohelper.php
+++ b/util/frphotohelper.php
@@ -60,7 +60,6 @@ $cookies = 'store/[data]/frphoto_cookie_' . $channel_address;
intval($channel['channel_id'])
);
if($r) {
- logger('frphotohelper: duplicate photo ignored');
killme();
}