X-Git-Url: https://mop.ddnsfree.com/gitweb/?a=blobdiff_plain;f=web%2FObj%2Fsac-a-push.phh;h=84f155527f34b5e97130bc13e10e2fa1325c7148;hb=296f0c5bf7e59c46e43c55f968c1e8af603f0073;hp=c14019215cc3cd6182bef2d74ccae54eeee2aa0c;hpb=2866ca461e9916336ef73fd199210955ab34cbb6;p=brisk.git diff --git a/web/Obj/sac-a-push.phh b/web/Obj/sac-a-push.phh index c140192..84f1555 100644 --- a/web/Obj/sac-a-push.phh +++ b/web/Obj/sac-a-push.phh @@ -1,5 +1,4 @@ rndstr = ""; for ($i = 0 ; $i < 4096 ; $i++) { if (($i % 128) == 0) - $thiz->rndstr .= "\n"; + $thiz->rndstr .= " "; else $thiz->rndstr .= chr(mt_rand(65, 90)); } @@ -416,7 +414,7 @@ class Sac_a_push { function run() { - GLOBAL $DOCUMENT_ROOT, $HTTP_HOST, $G_with_splash; + GLOBAL $DOCUMENT_ROOT, $HTTP_HOST, $G_with_splash, $G_black_list; if ($this->main_loop) { return (FALSE); @@ -547,6 +545,14 @@ class Sac_a_push { if ($line == "reload") { require("$DOCUMENT_ROOT/Etc/".BRISK_CONF); } + else if ($line == "shutdown") { + if ($this->app->dump_data()) { + exit(0); + } + else { + exit(1); + } + } } else { $key = array_search("$sock", $this->socks);