nodejs/node · info
extra input\n
Error message
extra input\n
What it means
Informational verbose message at brotli.c:1267, printed only when verbosity > 0 AND context->allow_concatenated is true. After a brotli stream decodes successfully (BROTLI_DECODER_RESULT_SUCCESS), if there are still bytes remaining in the file, the tool treats this as a concatenated multi-stream brotli file. It destroys the current decoder, creates a fresh one via InitDecoder, and continues decoding the next stream. This message is not an error — it signals normal concatenated-stream processing.
Source
Thrown at deps/brotli/c/tools/brotli.c:1267
} else if (result == BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT) {
if (!ProvideOutput(context)) return BROTLI_FALSE;
} else if (result == BROTLI_DECODER_RESULT_SUCCESS) {
if (!FlushOutput(context)) return BROTLI_FALSE;
BROTLI_BOOL has_more_input = (context->available_in != 0);
int extra_char = EOF;
if (!has_more_input) {
extra_char = fgetc(context->fin);
if (extra_char != EOF) {
has_more_input = BROTLI_TRUE;
context->input[0] = (uint8_t)extra_char;
context->next_in = context->input;
context->available_in = 1;
}
}
if (has_more_input) {
if (context->allow_concatenated) {
if (context->verbosity > 0) {
fprintf(stderr, "extra input\n");
}
if (!ProvideOutput(context)) return BROTLI_FALSE;
BrotliDecoderDestroyInstance(context->decoder);
context->decoder = NULL;
if (!InitDecoder(context)) return BROTLI_FALSE;
s = context->decoder;
} else {
fprintf(stderr, "corrupt input [%s]\n",
PrintablePath(context->current_input_path));
if (context->verbosity > 0) {
fprintf(stderr, "reason: extra input\n");
}
return BROTLI_FALSE;
}
} else {
if (context->verbosity > 0) {
context->end_time = clock();
fprintf(stderr, "Decompressed ");View on GitHub (pinned to 1b2de5e052)
Solutions
- No action needed — this is expected behavior when decompressing concatenated brotli streams with -v enabled.
- If the message is noisy, run without -v to suppress it.
- If you did not expect concatenated streams, investigate whether the source inadvertently appended multiple brotli files together.
Defensive patterns
Strategy: validation
Validate before calling
// This is informational, not an error. No validation needed. // If you want to detect concatenated streams programmatically: // after BrotliDecoderResult SUCCESS, check if fgetc(fin) != EOF.
Prevention
- Recognize this as expected behavior for multi-stream brotli files.
- Run without -v if the message is undesirable.
- Document that concatenated brotli streams are supported by default in the brotli tool.
When it happens
Trigger: Decompressing a file that contains two or more brotli streams concatenated back-to-back (a valid brotli convention). After the first stream reaches SUCCESS, the code peeks one extra byte with fgetc; if it is not EOF, has_more_input is set. With allow_concatenated enabled (the default for the brotli -d command), the tool logs this message and reinitializes the decoder for the next stream.
Common situations: Decompressing a file produced by concatenating multiple brotli-compressed chunks (common in web bundling, CDNI, or streaming compression pipelines). A developer runs 'brotli -d -v multi.br' and sees this informational line for each concatenated segment.
Related errors
- reason: comment mismatch\n
- reason: truncated input\n
- reason: extra input\n
- empty output file name for [%s] input file\n
- input file [%s] suffix mismatch\n
AI-assisted analysis of nodejs/node@1b2de5e052 (2026-08-13).
Data as JSON: /api/errors/ca1926e74056a55b.
Report an issue: GitHub.