pike.git / lib / master.pike.in

version» Context lines:

pike.git/lib/master.pike.in:1:   /* -*- Pike -*-    * -  * $Id: master.pike.in,v 1.152 2001/04/09 11:02:18 hubbe Exp $ +  * $Id: master.pike.in,v 1.153 2001/04/17 08:41:58 mirar Exp $    *    * Master-file for Pike.    *    * Based on master.pike 1.67.    */      // Some configurable parameters useful for debugging      #pike __REAL_VERSION__   #define PIKE_AUTORELOAD
pike.git/lib/master.pike.in:1241:   string _pike_file_name;   string _master_file_name;      //flag. Gets set to 1 if we're in async-mode (script->main() returned <0)   private int _async=0;      int asyncp() {    return _async;   }    + // The backend_thread() function is useful to determine if you are + // the backend thread - important when doing async/sync protocols +  + #if constant(thread_create) + // this must be done in __init if someone inherits the master + static object _backend_thread=this_thread(); + object backend_thread() + { +  return _backend_thread; + } + #endif +    /* This function is called when all the driver is done with all setup    * of modules, efuns, tables etc. etc. and is ready to start executing    * _real_ programs. It receives the arguments not meant for the driver    * and an array containing the environment variables on the same form as    * a C program receives them.    */   void _main(array(string) orig_argv, array(string) env)   {    array(string) argv=copy_value(orig_argv);    int i,debug,trace;    object tmp;    string a,b;    array q;    string postparseaction=0;    mixed v;       _pike_file_name = orig_argv[0]; -  + #if constant(thread_create) +  _backend_thread = this_thread(); + #endif       foreach(env,a)    {    if(sscanf(a,"%s=%s",a,b))    {    if(a=="") // Special hack for NT    {    sscanf(b,"%s=%s",a,b);    a="="+a;    }