def removeOldRequests
      now = Time.new
      @requestedPieces.length.times do |i|
        if @requestedPieces.set? i
          if now - @pieceRequestTime[i] > @requestTimeout
            @requestedPieces.clear i
            @pieceRequestTime[i] = nil
          end
        end
      end
    end
def removeOldRequests
      now = Time.new
      @requestedPieces.length.times do |i|
        if @requestedPieces.set? i
          if now - @pieceRequestTime[i] > @requestTimeout
            @requestedPieces.clear i
            @pieceRequestTime[i] = nil
          end
        end
      end
    end
Remove any pending requests after a timeout.