On Wed, Sep 4, 2024 at 9:15 AM Miguel Ojeda <miguel.ojeda.sandonis@xxxxxxxxx> wrote: > > On Tue, Sep 3, 2024 at 9:49 PM Nicolas Schier <nicolas@xxxxxxxxx> wrote: > > > > thanks, no objections. > > Thanks for taking a look! > > > I'd rather like to have > > > > output=$(echo "$output" | sed -nE 's/v([0-9]+)\.([0-9][0-9])/\1\2/p') > > > > here (thus, explicitly check against a two number subversion), so that > > we can detect also versions like 1.100 or 2.1 and bail out. > > So I didn't change that here to avoid more changes in the same commit, > but happy to do that if preferred. > > However, do we want to make it too strict? i.e. I don't think it is > very unexpected to get v1.100 or v2.1 -- it may not be what current > `pahole` does or ever do, but I am not sure we gain much by being so > strict. I am not sure whether pahole never releases v2.0 $ echo v2.0 | sed -nE 's/v([0-9]+)\.([0-9]+)/\1\2/p' 20 Not a syntax error, but the version comparison will not work correctly. > > (Similarly, for the ^..$ suggestion, it could be that `pahole` decides > to to something like `pahole v1.25`, i.e. `name version`, like other > programs). > > Either way, I am happy -- I doubt `pahole` changes too much, and if it > does, we can change this too. > > Cheers, > Miguel > -- Best Regards Masahiro Yamada