Skip to content

Fix varpeek parsing for hyphenated paths - #172

Closed
dajiaohuang wants to merge 1 commit into
adsr:masterfrom
dajiaohuang:fix/varpeek-hyphenated-path-c1-608
Closed

dajiaohuang wants to merge 1 commit into
adsr:masterfrom
dajiaohuang:fix/varpeek-hyphenated-path-c1-608

Conversation

@dajiaohuang

Copy link
Copy Markdown
Contributor

varpeek_add searched for - across the entire varspec. For the documented single-line form <varname>@<path>:<line>, a hyphen in the file path can be mistaken for the optional range delimiter. The resulting line-end parse is zero, so the requested variable is never registered and no peek record is emitted.

Search for the range delimiter only after the final : and add a synthetic PHP fixture whose filename contains a hyphen.

Validation: bash -n tests/test_varpeek_hyphen.sh and git diff --check pass. The full C build, PHP/ptrace integration test, and ShellCheck were not run locally: this Windows/MSYS host lacks the Linux ptrace environment and the cc, php, and make tools. The new test is included by the existing make test wildcard and traces only its own synthetic PHP child in the supported Linux CI environment.

@adsr

adsr commented Oct 22, 2026

Copy link
Copy Markdown
Owner

Merged in 1a07743. I adjusted the test a bit and preserved your authorship. Thank you.

@adsr adsr closed this Oct 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants