Skip to content

[BUG] Panick when piping help command #1293

@redacean

Description

@redacean

Describe the bug
Running the command feroxbuster --help | grep "-r" produces the output below.

Usage: grep [OPTION]... PATTERNS [FILE]...
Try 'grep --help' for more information.

thread 'main' panicked at src/parser.rs:747:35:
called `Result::unwrap()` on an `Err` value: Os { code: 32, kind: BrokenPipe, message: "Broken pipe" }
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

To Reproduce
Steps to reproduce the behavior:

  1. feroxbuster 2.13.0, grep (GNU grep) 3.11
  2. run feroxbuster --help | grep "-r"

Expected behavior
Regardless of the grep command being invalid, would not expect feroxbuster to crash.

Environment (please complete the following information):

  • feroxbuster version: v2.13.0
  • OS Ubuntu 24.04.3 LTS

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions