static function kill($exec_id) { if (!EIStream::isStream($exec_id) || EIStream::finish($exec_id)) { return "<ei_stream state='finish' />"; } $aux = EIStream::getPID($exec_id); if ($aux === FALSE) { return "<ei_stream state='unknown' />"; } exec("bin/misc/killproc.sh " . $aux); exec("touch " . EIStream::path($id) . "terminated"); return "<ei_stream state='stopped' />"; }