Re: Tests failing on CentOS 6

2020-08-17 Thread Peter

On 17/08/20 9:17 pm, Timo Sirainen wrote:

Looks like it's a gcc bug. It's not initializing the end_of_lines field in the 
unit test. Since it's in the unit test only, it's not harmful. Of course, the 
same gcc bug could be hitting some important places in the code.. but that's 
not a new issue. Only this unit test is really new and exposing this issue.


i wasn't sure if it was the test that was the issue or the code that it 
was testing which is why I'm reluctant to disable the unit tests unless 
I have to.



The problem goes away with:


Thanks for the patch, it does indeed fix the issue at hand.

I suppose the other way to deal with this might be to use gcc from 
devtoolset 9, but I prefer to stick with the CentOS stock GCC if at all 
possible.


Now I'm getting a different failure when building the i386 packages 
which was already reported by someone else.  I will follow up on this 
one in that thread.



Peter


Re: Tests failing on CentOS 6

2020-08-17 Thread Timo Sirainen
On 15. Aug 2020, at 14.18, Peter  wrote:
> 
> Getting this when attempting to build 2.3.11.3 on CentOS 6:
> 
> test-mail-cache.c:176: Assert failed: 
> strcmp(str_c(str),"123\nfoo\n456\nbar\n")
>"" != "123
> foo
> 456
> bar
> "
> test-mail-cache.c:176: Assert failed: 
> strcmp(str_c(str),"123\nfoo\n456\nbar\n")
>"" != "123
> foo
> 456
> bar
> "
> mail cache uncommitted lookups ... : 
> FAILED
> 
> Full make check output is at https://paste.centos.org/view/b48d38a9
> 
> I can provide full build logs if you want, but that's a 4M file so I'll 
> provide it upon request.
> 
> For now I'm going ot have to bypass the make check stage of the build for 
> CentOS 6, but I worry that the failed check could be indicative of something 
> critical.

Looks like it's a gcc bug. It's not initializing the end_of_lines field in the 
unit test. Since it's in the unit test only, it's not harmful. Of course, the 
same gcc bug could be hitting some important places in the code.. but that's 
not a new issue. Only this unit test is really new and exposing this issue.

The problem goes away with:

diff --git a/src/lib-index/test-mail-cache.c b/src/lib-index/test-mail-cache.c
index e4e5503f6..4734904e8 100644
--- a/src/lib-index/test-mail-cache.c
+++ b/src/lib-index/test-mail-cache.c
@@ -130,11 +130,13 @@ static void test_mail_cache_fields(void)
struct test_header_data header_data1 = {
.line1 = 15,
.line2 = 30,
+   .end_of_lines = 0,
.headers = "foo\nbar\n",
};
struct test_header_data header_data2 = {
.line1 = 10,
.line2 = 20,
+   .end_of_lines = 0,
.headers = "123\n456\n",
};
mail_cache_add(cache_trans, 1, cache_fields[TEST_FIELD_HEADER1].idx,

Tests failing on CentOS 6

2020-08-15 Thread Peter

Getting this when attempting to build 2.3.11.3 on CentOS 6:

test-mail-cache.c:176: Assert failed: 
strcmp(str_c(str),"123\nfoo\n456\nbar\n")

"" != "123
foo
456
bar
"
test-mail-cache.c:176: Assert failed: 
strcmp(str_c(str),"123\nfoo\n456\nbar\n")

"" != "123
foo
456
bar
"
mail cache uncommitted lookups ... : 
FAILED


Full make check output is at https://paste.centos.org/view/b48d38a9

I can provide full build logs if you want, but that's a 4M file so I'll 
provide it upon request.


For now I'm going ot have to bypass the make check stage of the build 
for CentOS 6, but I worry that the failed check could be indicative of 
something critical.



Peter