Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-122110

BufferBuilder not expanding under specific conditions.


    • Icon: Bug Bug
    • Resolution: Fixed
    • Minecraft 1.13-pre6
    • Minecraft 1.12.2
    • None
    • Unconfirmed

      The following is based off MCP namings snapshot_20171003 and the Forge PR fix can be found Here.
      There is a specific set of conditions in witch BufferBuilder will not properly expand its buffer, For example, if the buffer is filled or extremely close to using 'addVertexData' calls to 'pos', 'tex' and so on will cause the buffer to overflow, as 'addVertexData' only checks if there is enough room for the current quad whilst 'endVertex' checks if there is enough room for the next vertex. This can be mitigated by altering 'addVertexData's call to 'growBuffer' to check if there is enough room for the data provided plus the next vertex.

            grum [Mojang] Grum (Erik Broes)
            covers1624 covers1624
            3 Vote for this issue
            2 Start watching this issue