- Put attached json file into android assets folder
- Run this code anywhere in the application
JsonReader reader = new JsonReader(); JsonValue jsonValue = reader.parse(Gdx.files.internal("ArrayException.json"));
jsonValue.get("TestArray").get("Type");
- Observe that null pointer is being thrown.
JsonValue.get(String name) is not checking whether name is not null, causing null pointer.
Comment #1
Posted on Sep 11, 2014 by Swift CatThe libGDX issue tracker has been moved to https://github.com/libgdx/libgdx/issues. This issue tracker is not monitored and should not be used. To prevent others from using this issue tracker, I will close this issue now. If you haven't done so already, please consider posting your issue on the new issue tracker at https://github.com/libgdx/libgdx/issues.
Status: Invalid
Labels:
Type-Defect
Priority-Medium