Hacker Newsnew | past | comments | ask | show | jobs | submit | Jehops's commentslogin

> That's not correct because the `m` flag gets enabled by the multiline option.

Is this documented? RG(1) only says

            -m, --max-count <NUM>
            Limit the number of matching lines per files searched to NUM.
Is this a different option or is there an implied <NUM> that prevents 'rg -U ^' from searching from the beginning of the file?


In this context the "m flag" refers to a flag inside the regex syntax. That is, when you use ripgrep's regex library as a standalone (as Rust programmers do), then '^' only matches at the beginning of text, where as '(?m)^' enables multi-line mode and thus permits to match at either the beginning of text or at the beginning of a line.

ripgrep also has a -U/--multiline flag, but it's orthogonal to the regex mode called multiline. It's an unfortunate naming clash, but they are names in otherwise distinct namespaces.

ripgrep always enables the regex flag 'm', regardless of whether -U/--multiline is enabled or not.


Thank you for taking the time to explain!


I don't see any mention of Stagefright in the article.


Looks like the moderators switched out the article. It used to point to this one https://threatpost.com/android-stagefright-flaws-put-950-mil...


"The problem is that Stagefright is an over-privileged application with system access on some devices, which enables privileges similar to apps with root access. Stagefright is used to process a number of common media formats, and it’s implemented in native C++ code, making it simpler to exploit

This is huge.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: