Clarify that decoding too many Huffman weights is a failure condition
diff --git a/doc/zstd_compression_format.md b/doc/zstd_compression_format.md
index 0532a84..b64ddc3 100644
--- a/doc/zstd_compression_format.md
+++ b/doc/zstd_compression_format.md
@@ -1353,6 +1353,9 @@
 remain in the stream, it is assumed that extra bits are 0.  Then,
 symbols for each of the final states are decoded and the process is complete.
 
+If this process would produce more weights than the maximum number of decoded
+weights (255), then the data is considered corrupted.
+
 #### Conversion from weights to Huffman prefix codes
 
 All present symbols shall now have a `Weight` value.