Mojira Archive
MC-124174

Game crash when give yourself an item with empty name

The bug

Running the command

/give @p minecraft:diamond_sword{display:{Name:""}}

will say "An unexpected error occurred trying to execute that command" but will still give you the item. When you hold it, the game will crash.

Crash report

Description: Rendering screen

java.lang.NullPointerException: Rendering screen
	at anw.a(SourceFile:554)
	at brs.a(SourceFile:99)
	at brs.a(SourceFile:95)
	at bsw.a(SourceFile:686)
	at bsn.b(SourceFile:176)
	at bsw.a(SourceFile:643)
	at cau.a(SourceFile:990)
	at bob.b(SourceFile:822)
	at bob.a(SourceFile:382)
	at net.minecraft.client.main.Main.main(SourceFile:140)

Fixed

PlanetNebulirion

[Mojang] Bartosz Bok

2018-01-11, 08:26 PM

2020-08-23, 09:57 PM

2018-06-15, 09:04 PM

7

5

Confirmed

item-Name, text-component

Minecraft 18w02a - Minecraft 1.13-pre2Minecraft 18w02a, Minecraft 18w03b, Minecraft 18w05a, Minecraft 18w11a, Minecraft 18w20b, Minecraft 18w22a, Minecraft 18w22b, Minecraft 18w22c, Minecraft 1.13-pre1, Minecraft 1.13-pre2

Minecraft 1.13-pre3