X-Git-Url: http://mop.ddnsfree.com/gitweb/?a=blobdiff_plain;f=web%2FObj%2Fsac-a-push.phh;h=5f9818a274e891574780a88b13605efd8506e886;hb=bd3aa68b123e6af44c44f3b155d280b40bbd7bd6;hp=6ed7a0e6a5fe300d6bc1e4256e940618efeeb57e;hpb=ad9bfccebd7532f3283ef6cc0733a47973c9a44e;p=brisk.git diff --git a/web/Obj/sac-a-push.phh b/web/Obj/sac-a-push.phh index 6ed7a0e..5f9818a 100644 --- a/web/Obj/sac-a-push.phh +++ b/web/Obj/sac-a-push.phh @@ -156,6 +156,8 @@ function spu_process_info($stream_info, &$method, &$header, &$get, &$post, &$coo printf("A COUNT: [%s] %d\n", $a[0], count($a)); for ($i = 0 ; $i < count($a) ; $i++) { $b = explode('=', $a[$i]); + if ($b[0] == "") + continue; $get[$b[0]] = urldecode($b[1]); } } @@ -874,6 +876,13 @@ class Sac_a_push { $id = intval($sock); if (isset($this->s2u[$id])) { $user = $this->s2u[$id]; + + if ($user->rd_toflush) { + if (fflush($sock) == FALSE) + continue; + else + $user->rd_toflush = FALSE; + } $response = $user->rd_cache_get(); $do_ping = FALSE; if (($this->curtime - $user->lacc) > (EXPIRE_TIME_RD / 3)) { @@ -911,7 +920,10 @@ class Sac_a_push { else { $user->rd_cache_set(""); } - fflush($sock); + if (fflush($sock) == FALSE) { + $user->rd_toflush = TRUE; + continue; + } $user->rd_kalive_reset($this->curtime); } @@ -931,7 +943,9 @@ class Sac_a_push { } // if (isset($this->s2u[$id]... } // foreach ($this->socks... printf("\n"); - $this->app->cds->process(); + if (defined('CURL_DE_SAC_VERS')) { + $this->app->cds->process(); + } } // while (... } // function run(...