Mojira Archive
MC-131154

Resource locations allow empty path pieces

The bug

Resource locations allow empty path pieces:

  • Only a namespace: minecraft:
  • Trailing slash: minecraft:test/
  • Two slashes without any other characters between them: minecraft:test//test2

This allows for example saving structures without a name.

Additionally starting with 1.13-pre2, and likely caused by the fix of MC-131153, using an empty first path piece (for example minecraft:/test/a) uses the C:\ directory as parent directory.

How to reproduce

  1. /setblock ~ ~ ~ structure_block[mode=save]{mode:"SAVE",name:"minecraft:"}
    
  2. Open the structure block GUI and click "SAVE"
    Instead of seeing the error message "Invalid structure name", the structure is saved as .nbt

Fixed

Marcono1234

[Mojang] Bartosz Bok

2018-06-10, 12:50 AM

2018-06-18, 10:53 AM

2018-06-18, 10:53 AM

4

2

Confirmed

resource-location, structure_block

Minecraft 1.12.2, Minecraft 1.13-pre1, Minecraft 1.13-pre2

Minecraft 1.13-pre3