Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
3.0.2
-
None
-
Arch: s390x (big endian)
OS: SLES 12 SP3
Description
Test 'unicode' is failing with segmentaion fault on s390x.
At ma_error.c:289 casting of (MARIADB_CHARSET_INFO **) into (Client_Charset *) is done which causes garbage values on s390x but not on x86.
Creating a new Client_Charset object and passing its address to MADB_SetString is fixing the segmentation fault at this point,
if (SQLState){ |
Client_Charset utf8_={CP_UTF8,mariadb_get_charset_by_name("utf8")}; |
MADB_SetString(isWChar ? &utf8_ : 0, (void *)SQLState, SQL_SQLSTATE_SIZE + 1, |
SqlStateVersion, SQL_SQLSTATE_SIZE, &InternalError);
|
}
|
but after execution goes ahead segmentation fault occurs at ma_error.c:289
if (MessageText) |
Length= (SQLSMALLINT)MADB_SetString(isWChar ? &utf8 : 0, (void*)MessageText, BufferLength, |
Err->SqlErrorMsg, strlen(Err->SqlErrorMsg), &InternalError);
|
Could you please suggest a fix?
Attached gdb logs for s390x and x86.
Attachments
Issue Links
- is part of
-
ODBC-128 Maria ODBC test failures on s390x architecture
- Closed