Hi, I would like to ask for an explanation or hint to my error for my attempt to use regexec(3) to match null-characters ('\0'). To illustrate it, I wrote the attached test-program and what I do not understand is why I get false match-positions when testing with a string that contains '\0' (I am not absolutely sure if '.' is supposed to match '\0'). Here is some "normal" output: $ printf ".\nab\n" | ./test_regex Compiling regex "." Testing string "ab"... regexec match: pos 0 length 1 "ab" Testing string "b"... regexec match: pos 1 length 1 "b" Testing string ""... But when I insert a '\0' into that string, the result is confusing to me: $ printf ".\na\0b\n" | ./test_regex Compiling regex "." Testing string "a"... regexec match: pos 0 length 1 "a" Testing string ""... regexec match: pos 2 length 1 "b" Testing string "b"... regexec match: pos 2 length 1 "b" Testing string ""... My appologies in advance should this question be easy to answer myself if I had googled it correctly. Regards, Dirk