Bass23

Blitz3D Forums/Blitz3D Userlibs/Bass23

Bug in BBS 1.6.1 and previous (modinfo.bb)

Modinfo "can" crash if you try to get informations (note/fx) of the last pattern in a mod. Please search this codelines in modinfo.bb (from line 212)

SeekFile (tempmod, 952)
	Dim MOD_OrderList%(MOD_Orders-1) ;get orders and last pattern
		MOD_Patterns = 0
		For i = 0 To (MOD_Orders-1)
			temp = ReadByte (tempmod)
			If temp > MOD_Patterns  Then MOD_Patterns = (temp+1)
		MOD_OrderList (i) = temp
		Next


and replace it with this

SeekFile (tempmod, 952)
	Dim MOD_OrderList%(MOD_Orders-1) ;get orders and last pattern
		MOD_Patterns = 0
		For i = 0 To (MOD_Orders-1)
			temp = ReadByte (tempmod)
			If temp > MOD_Patterns  Then MOD_Patterns = temp
		MOD_OrderList (i) = temp
		Next
		MOD_Patterns=MOD_Patterns+1; add last pattern


bye