mirror of
https://github.com/friendica/friendica
synced 2024-12-22 16:40:16 +00:00
Restructured the way, processes are inserted and removed
This commit is contained in:
parent
22f32d9721
commit
1caa87dce6
22 changed files with 5 additions and 44 deletions
2
boot.php
2
boot.php
|
@ -1736,8 +1736,6 @@ function login($register = false, $hiddens=false) {
|
|||
*/
|
||||
function killme() {
|
||||
|
||||
get_app()->end_process();
|
||||
|
||||
if (!get_app()->is_backend())
|
||||
session_write_close();
|
||||
|
||||
|
|
|
@ -58,8 +58,6 @@ if(is_null($db)) {
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
// the logfile to which to write, should be writeable by the user which is running the server
|
||||
$sLogFile = get_config('jabber','logfile');
|
||||
|
||||
|
|
|
@ -19,8 +19,6 @@ function cli_startup() {
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/session.php');
|
||||
|
||||
load_config('config');
|
||||
|
|
|
@ -27,8 +27,6 @@ function cron_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/session.php');
|
||||
require_once('include/datetime.php');
|
||||
require_once('include/items.php');
|
||||
|
|
|
@ -17,8 +17,6 @@ function cronhooks_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/session.php');
|
||||
require_once('include/datetime.php');
|
||||
|
||||
|
|
|
@ -27,8 +27,6 @@ function cronjobs_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/session.php');
|
||||
require_once('include/datetime.php');
|
||||
require_once('include/ostatus.php');
|
||||
|
|
|
@ -1467,8 +1467,6 @@ function dbstructure_run(&$argv, &$argc) {
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
}
|
||||
|
||||
$a->start_process();
|
||||
|
||||
if ($argc==2) {
|
||||
switch ($argv[1]) {
|
||||
case "update":
|
||||
|
|
|
@ -16,8 +16,6 @@ function dbupdate_run(&$argv, &$argc) {
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
}
|
||||
|
||||
$a->start_process();
|
||||
|
||||
load_config('config');
|
||||
load_config('system');
|
||||
|
||||
|
|
|
@ -21,8 +21,6 @@ function delivery_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
}
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once("include/session.php");
|
||||
require_once("include/datetime.php");
|
||||
require_once('include/items.php');
|
||||
|
|
|
@ -15,8 +15,6 @@ function directory_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
load_config('config');
|
||||
load_config('system');
|
||||
|
||||
|
|
|
@ -18,8 +18,6 @@ function discover_poco_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/session.php');
|
||||
require_once('include/datetime.php');
|
||||
|
||||
|
|
|
@ -16,8 +16,6 @@ function expire_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/session.php');
|
||||
require_once('include/datetime.php');
|
||||
require_once('include/items.php');
|
||||
|
|
|
@ -18,8 +18,6 @@ function gprobe_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/session.php');
|
||||
require_once('include/datetime.php');
|
||||
|
||||
|
|
|
@ -54,8 +54,6 @@ function notifier_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
}
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once("include/session.php");
|
||||
require_once("include/datetime.php");
|
||||
require_once('include/items.php');
|
||||
|
|
|
@ -24,8 +24,6 @@ function onepoll_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/session.php');
|
||||
require_once('include/datetime.php');
|
||||
require_once('include/items.php');
|
||||
|
|
|
@ -333,7 +333,10 @@ function poller_active_workers() {
|
|||
}
|
||||
|
||||
if (array_search(__file__,get_included_files())===0){
|
||||
poller_run($_SERVER["argv"],$_SERVER["argc"]);
|
||||
killme();
|
||||
poller_run($_SERVER["argv"],$_SERVER["argc"]);
|
||||
|
||||
get_app()->end_process();
|
||||
|
||||
killme();
|
||||
}
|
||||
?>
|
||||
|
|
|
@ -70,8 +70,6 @@ function pubsubpublish_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/items.php');
|
||||
|
||||
load_config('config');
|
||||
|
|
|
@ -17,8 +17,6 @@ function queue_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once("include/session.php");
|
||||
require_once("include/datetime.php");
|
||||
require_once('include/items.php');
|
||||
|
|
|
@ -14,8 +14,6 @@ if(is_null($db)) {
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
}
|
||||
|
||||
$a->start_process();
|
||||
|
||||
load_config('config');
|
||||
load_config('system');
|
||||
|
||||
|
|
|
@ -14,8 +14,6 @@ if(is_null($db)) {
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
}
|
||||
|
||||
$a->start_process();
|
||||
|
||||
load_config('config');
|
||||
load_config('system');
|
||||
|
||||
|
|
|
@ -14,8 +14,6 @@ if(is_null($db)) {
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
}
|
||||
|
||||
$a->start_process();
|
||||
|
||||
load_config('config');
|
||||
load_config('system');
|
||||
|
||||
|
|
|
@ -16,8 +16,6 @@ function update_gcontact_run(&$argv, &$argc){
|
|||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
$a->start_process();
|
||||
|
||||
require_once('include/Scrape.php');
|
||||
require_once("include/socgraph.php");
|
||||
|
||||
|
|
Loading…
Reference in a new issue