)]}'
{
  "commit": "a81f97769c5b8cad0bedb4ada88981b213389d1e",
  "tree": "706766d1645ac45934646de255fbdd0c92ecf939",
  "parents": [
    "d89c4b1c52e25ddafe047bc78bbee5c1e24b1809"
  ],
  "author": {
    "name": "Brotli",
    "email": "no-reply@google.com",
    "time": "Fri Nov 06 11:12:32 2026 -0800"
  },
  "committer": {
    "name": "Copybara-Service",
    "email": "copybara-worker@google.com",
    "time": "Thu Nov 12 13:37:39 2026 -0800"
  },
  "message": "Preserve shared dictionary state on serialized parse failure.\n\nWhen attaching a serialized shared dictionary (`BROTLI_SHARED_DICTIONARY_SERIALIZED`), `ParseDictionary` previously mutated `BrotliSharedDictionary` fields in-place before validating all entries and did not roll back on error. If parsing failed partway through (such as when a `context_map` entry exceeded `num_dictionaries` or when input ended before all `(words_index, transforms_index)` pairs were read), `BrotliSharedDictionaryAttach` returned `BROTLI_FALSE` while leaving the dictionary in a partially populated state. Subsequent decompression calls that proceeded after a failed attachment could then index out of bounds of `words` and `transforms` or dereference null dictionary pointers. In addition, attaching a prefix-only serialized dictionary (`num_word_lists \u003d\u003d 0` and `num_transform_lists \u003d\u003d 0`) onto a `BrotliSharedDictionary` that already had custom word or transform lists previously overwrote those custom tables with the built-in static dictionary.\n\nValidate `num_word_lists`, `num_transform_lists`, `num_dictionaries`, `context_based`, and `context_map` entries using local variables before committing them to `BrotliSharedDictionary` (preserving existing custom word and transform lists when appending a prefix-only serialized dictionary), and restore the prior dictionary state (freeing any newly allocated word, transform, or prefix-suffix tables) in `DecodeSharedDictionary` whenever `ParseDictionary` fails.\n\nPiperOrigin-RevId: 1015703989\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "cef4e20fcd8ac1c5a5fdbb127b8459cef2de9b2d",
      "old_mode": 33188,
      "old_path": "c/common/shared_dictionary.c",
      "new_id": "1530906f691190167ed5470b4321df421754a135",
      "new_mode": 33188,
      "new_path": "c/common/shared_dictionary.c"
    }
  ]
}
