﻿id	summary	reporter	owner	description	type	status	milestone	component	version	severity	resolution	keywords	cc
1352	StringSplit hard crash on binary data	MrCreatoR <mscreator@…>	Jon	"Theese examples will show that script is crashing when using StringSplit on binary data:

'''Crashing:'''

{{{
$sFile = @Systemdir & ""\oobe\images\hand1.gif""

$hFile = FileOpen($sFile, 16)
$aRead = StringSplit(FileRead($hFile), @CRLF)
FileClose($hFile)

MsgBox(64, 'Title', 'Crash!') ;Not Shown
}}}


'''Not crashing: (FileRead is stored in variable)'''

{{{
$sFile = @Systemdir & ""\oobe\images\hand1.gif""

$hFile = FileOpen($sFile, 16)
$sRead = FileRead($hFile)

$aRead = StringSplit($sRead, @CRLF)

FileClose($hFile)

MsgBox(64, 'Title', 'No Crash!') ;Not Shown

}}}

'''And crashing again:'''

{{{
$sFile = @Systemdir & ""\oobe\images\hand1.gif""

$hFile = FileOpen($sFile, 16)
$sRead = FileRead($hFile)
FileClose($hFile)

$aRead = StringSplit($sRead, @CRLF)

MsgBox(64, 'Title', 'No Crash!') ;Not Shown
}}}

In the last example we can see that FileClose is called ''before'' StringSplit, for some reason that itself causing a hard crash."	Bug	closed	3.3.3.2	AutoIt	3.3.0.0	None	Fixed		
