Mojira Archive
MC-261454

ServerGamePacketListenerImpl.updateSignText clears playerWhoMayEdit even if other player is editing

The bug

(This is based on the decompiled code of 23w13a using Mojang mappings; I currently don't have a working setup to test this)

The method net.minecraft.server.network.ServerGamePacketListenerImpl.updateSignText looks like this:

signBlockEntity.updateSignText(this.player, serverboundSignUpdatePacket.isFrontText(), list);
signBlockEntity.setAllowedPlayerEditor(null);

If another player A is already editing the sign, and player B sends a ServerboundSignUpdatePacket, then updateSignText refuses to update the text and logs a warning. However the setAllowedPlayerEditor call shown above nonetheless clears the editing player A.

That allows player B to click the sign again and edit it, even though player A was originally editing it.

A reasonable fix might be to move the setAllowedPlayerEditor(null) call inside updateSignText.

Fixed

Marcono1234

[Mojang] elvendorke

2023-03-30, 09:55 PM

2023-04-05, 07:42 AM

2023-04-05, 07:42 AM

2

3

Plausible

Important

Expansion A

Networking

23w13a

23w14a