changeset 131:acaa01b90505 beta-mhg-5

'Clear' no longer needs to run this loop.
author Farmbuyer of US-Kilrogg <farmbuyer@gmail.com>
date Mon, 27 Aug 2012 03:24:38 -0400
parents 08d3d2b7c31d
children 64e3b96a8626
files gui.lua
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/gui.lua	Mon Aug 27 02:59:49 2012 -0400
+++ b/gui.lua	Mon Aug 27 03:24:38 2012 -0400
@@ -384,15 +384,17 @@
 	if #g_loot < 1 then
 		--pprint('_f_o_e_d', "#g_loot<1")
 		self.loot_clean = nil
-		opt_starting_index = nil
+		return
 	end
 
 	local display_bcast_from = self.db.profile.display_bcast_from
 	local colcount = #eoi_st_cols
 
-	-- 'while true' so that we can use (inner) break as (outer) continue
 	local start = opt_starting_index or
 		math_min (#g_dloot, self.loot_clean or math_huge, #g_loot)
+	if start < 1 then return end
+
+	-- 'while true' so that we can use (inner) break as (outer) continue
 	for i = start, #g_loot do while true do
 		local e = g_dloot[i]
 		if e == nil then