use ... use FCGI; $fcgicnt = 0; while (FCGI::accept >= 0) { &parsecontroller; &getdata; &output; $fcgicnt++; } sub getdata {....