From: Yoann G. <jj...@us...> - 2004-09-29 12:18:14
|
Update of /cvsroot/ngetsuite/ngetsuite/ngetsuite In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17680/ngetsuite Modified Files: downloader.rb queue.rb Log Message: misc fixes Index: queue.rb =================================================================== RCS file: /cvsroot/ngetsuite/ngetsuite/ngetsuite/queue.rb,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** queue.rb 27 Sep 2004 14:59:40 -0000 1.30 --- queue.rb 29 Sep 2004 12:18:00 -0000 1.31 *************** *** 132,137 **** def to_s ! s = "#{yellow '<'}#{blue @_queueindex}#{yellow '>'} [#{red group}] #{yellow @_value},\n\tdest : #{green @_subdir},\n\tprio : #{@_priority}, status : #{@_status} " ! if (@_status == FAILED || @_status == PROCESSING) a = Db.dbh.select_all("select `status` from `queue_files` where `queueindex`='#{@_queueindex}'") s += ' ' + yellow('[') + a.map { |x| --- 132,137 ---- def to_s ! s = "#{yellow '<'}#{blue @_queueindex}#{yellow '>'} [#{red group}] #{yellow @_value}, dest : #{green @_subdir}, prio : #{@_priority}, status : #{@_status} " ! if (@_status == FAILED or @_status == PROCESSING or @_status == STOPPED) a = Db.dbh.select_all("select `status` from `queue_files` where `queueindex`='#{@_queueindex}'") s += ' ' + yellow('[') + a.map { |x| Index: downloader.rb =================================================================== RCS file: /cvsroot/ngetsuite/ngetsuite/ngetsuite/downloader.rb,v retrieving revision 1.41 retrieving revision 1.42 diff -C2 -d -r1.41 -r1.42 *** downloader.rb 27 Sep 2004 18:01:25 -0000 1.41 --- downloader.rb 29 Sep 2004 12:18:00 -0000 1.42 *************** *** 208,212 **** rescue IOError puts 'nget got killed!' ! parent.stop rescue Object => e puts 'Exception while parsing nget output: '+e.class.to_s, e.backtrace --- 208,219 ---- rescue IOError puts 'nget got killed!' ! if @curfile ! @curfile.finish_err ! @curfile.sync_to_db ! @curfile = nil ! end ! # unless requested by -k ! parent.stop if (@finish_status == 'FAILED') ! rescue Object => e puts 'Exception while parsing nget output: '+e.class.to_s, e.backtrace *************** *** 225,229 **** def stop(command=false) # oh no they killed kenny ! - ldebug red('dlder.stop') @finish_status = (command ? 'STOPPED' : 'PENDING') newstat = "`status`='#{@finish_status}',`date_finished`=NOW()" --- 232,235 ---- *************** *** 235,238 **** --- 241,245 ---- Process.kill('SIGTERM', @io.pid) @io.close + sleep 2 @t.exit |