mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
Try to fix failing tests
This commit is contained in:
@@ -1053,7 +1053,7 @@ PSZ JOBJECT::GetText(PGLOBAL g, PSZ text)
|
|||||||
return text;
|
return text;
|
||||||
|
|
||||||
if (!text) {
|
if (!text) {
|
||||||
text = (char*)PlugSubAlloc(g, NULL, 0);
|
text = (char*)PlugSubAlloc(g, NULL, 512); // TODO: get size
|
||||||
text[0] = 0;
|
text[0] = 0;
|
||||||
n = 1;
|
n = 1;
|
||||||
} else
|
} else
|
||||||
@@ -1079,8 +1079,8 @@ PSZ JOBJECT::GetText(PGLOBAL g, PSZ text)
|
|||||||
} else for (PJPR jp = First; jp; jp = jp->Next)
|
} else for (PJPR jp = First; jp; jp = jp->Next)
|
||||||
jp->Val->GetText(g, text);
|
jp->Val->GetText(g, text);
|
||||||
|
|
||||||
if (n)
|
//if (n)
|
||||||
PlugSubAlloc(g, NULL, strlen(text) + 1);
|
// PlugSubAlloc(g, NULL, strlen(text) + 1);
|
||||||
|
|
||||||
return text + n;
|
return text + n;
|
||||||
} // end of GetText;
|
} // end of GetText;
|
||||||
@@ -1290,7 +1290,7 @@ PSZ JARRAY::GetText(PGLOBAL g, PSZ text)
|
|||||||
PJVAL jp;
|
PJVAL jp;
|
||||||
|
|
||||||
if (!text) {
|
if (!text) {
|
||||||
text = (char*)PlugSubAlloc(g, NULL, 0);
|
text = (char*)PlugSubAlloc(g, NULL, 512);
|
||||||
text[0] = 0;
|
text[0] = 0;
|
||||||
n = 1;
|
n = 1;
|
||||||
} else
|
} else
|
||||||
@@ -1299,8 +1299,8 @@ PSZ JARRAY::GetText(PGLOBAL g, PSZ text)
|
|||||||
for (jp = First; jp; jp = jp->Next)
|
for (jp = First; jp; jp = jp->Next)
|
||||||
jp->GetText(g, text);
|
jp->GetText(g, text);
|
||||||
|
|
||||||
if (n)
|
//if (n)
|
||||||
PlugSubAlloc(g, NULL, strlen(text) + 1);
|
// PlugSubAlloc(g, NULL, strlen(text) + 1);
|
||||||
|
|
||||||
return text + n;
|
return text + n;
|
||||||
} // end of GetText;
|
} // end of GetText;
|
||||||
@@ -1536,8 +1536,7 @@ PSZ JVALUE::GetString(PGLOBAL g)
|
|||||||
p = (char*)PlugDup(g, (Val->B) ? "true" : "false");
|
p = (char*)PlugDup(g, (Val->B) ? "true" : "false");
|
||||||
break;
|
break;
|
||||||
case TYPE_NULL:
|
case TYPE_NULL:
|
||||||
p = (char*)PlugDup(g, "null")
|
p = (char*)PlugDup(g, "null");
|
||||||
;
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
p = NULL;
|
p = NULL;
|
||||||
|
Reference in New Issue
Block a user