index out of bounds exception when importing empty array
GoogleCodeExporter opened this issue · comments
Google Code Exporter commented
What steps will reproduce the problem?
1. call ReadYaml on a .yaml file containing a line with an empty array (e.g.
'foo: []'
What is the expected output? What do you see instead?
It should create an empty array but instead it gives the following error
message:
??? Java exception occurred:
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.RangeCheck(Unknown Source)
at java.util.ArrayList.get(Unknown Source)
Error in ==> Hash2Struct at 69
switch class(d.get(0))
Error in ==> ReadYaml>ReplaceImportByStruct at 63
s = Hash2Struct(ymlobj);
Error in ==> ReadYaml at 38
Data = ReplaceImportByStruct(yaml_file);
What version of the product are you using? On what operating system?
0.3.2 SLES10
Please provide any additional information below.
Original issue reported on code.google.com by cross...@gmail.com
on 23 Jun 2011 at 5:00
Google Code Exporter commented
Fixed in version 0.4.0
Original comment by JirkaCig...@gmail.com
on 9 Sep 2011 at 7:32
- Changed state: Fixed