Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RunGrepTest fails with musl C library #112

Closed
marv opened this issue Apr 27, 2022 · 3 comments
Closed

RunGrepTest fails with musl C library #112

marv opened this issue Apr 27, 2022 · 3 comments

Comments

@marv
Copy link

marv commented Apr 27, 2022

With musl 1.2.3 the RunGrepTest of pcre2 10.40 fails like this:

FAIL: RunGrepTest
=================

Testing pcre2grep version 10.40 2022-04-14
Testing pcre2grep main features
Testing pcre2grep UTF-8 features
Testing pcre2grep newline settings
Testing pcre2grep script callouts
--- ./testdata/grepoutputC      2021-08-20 16:51:28.000000000 +0000
+++ testtrygrep 2022-04-27 08:49:09.218242523 +0000
@@ -1,22 +1,22 @@
 Arg1: [T] [he ] [ ] Arg2: |T| () () (0)
+The quick brown
 Arg1: [T] [his] [s] Arg2: |T| () () (0)
 Arg1: [T] [his] [s] Arg2: |T| () () (0)
 Arg1: [T] [he ] [ ] Arg2: |T| () () (0)
 Arg1: [T] [he ] [ ] Arg2: |T| () () (0)
 Arg1: [T] [he ] [ ] Arg2: |T| () () (0)
-The quick brown
 This time it jumps and jumps and jumps.
 This line contains \E and (regex) *meta* [characters].
 The word is cat in this line
 The caterpillar sat on the mat
 The snowcat is not an animal
 Arg1: [qu] [qu]
+The quick brown
 Arg1: [ t] [ t]
 Arg1: [ l] [ l]
 Arg1: [wo] [wo]
 Arg1: [ca] [ca]
 Arg1: [sn] [sn]
-The quick brown
 This time it jumps and jumps and jumps.
 This line contains \E and (regex) *meta* [characters].
 The word is cat in this line
FAIL RunGrepTest (exit status: 1)

Any ideas what could be causing this behaviour? Or how to close in on it? I'm happy to do more testing with some pointers where to look :-)

Best regards,
Marvin

@ltrzesniewski
Copy link
Contributor

This has been fixed in 1bb2b97.

See #19 (comment)

@PhilipHazel
Copy link
Collaborator

Thanks for the report, but we are ahead of you! This was fixed a few days ago when a GitHub action was added to test in an Alpine container with musl. The commit is 3fec24a I believe. The problem was the ordering of different bits of stdout and the issue was fixed by adding a couple of fflush() calls to pcre2grep around line 2441. I'm going to close this, but please re-open if you don't find the HEAD code is fixed.

@marv
Copy link
Author

marv commented Apr 27, 2022

@ltrzesniewski @PhilipHazel All the better! :-) Good to know that it's already been fixed (sorry I didn't see that) and thanks for the explanation. I'll re-test this once 10.41 is released

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

No branches or pull requests

3 participants