mesalock-linux / mesabox

A collection of core system utilities written in Rust for Unix-like systems (and now Windows)
BSD 3-Clause "New" or "Revised" License
137 stars 19 forks source link

posix/sh: parser accepts invalid input #39

Closed Arcterus closed 6 years ago

Arcterus commented 6 years ago

For some reason the parser accepts echo hi | echo hello (echo hi; cat) | cat, which causes hello to be displayed on stdout. Based on testing, it seems to stop parsing when it sees the (echo hi; cat) part.

Arcterus commented 6 years ago

This was fixed by rewriting the parser to not use nom.