Skip to content

fix: LSP git diff subprocess has no timeout #13

Description

@EffortlessSteven

Problem

crates/diffguard-lsp/src/server.rs:928Command::new("git").output() blocks the LSP server indefinitely on large repos. No timeout configured.

Fix

Add a timeout (e.g., 10 seconds) and kill_on_drop to the std::process::Command. Consider using tokio::process::Command with tokio::time::timeout.

Source

PR #5 review — CodeRabbit (comment #22).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions