mirror of https://github.com/milvus-io/milvus.git
Fill trailing \0 for c metrics value (#26578)
Signed-off-by: Congqi Xia <congqi.xia@zilliz.com>pull/26589/head
parent
809c7a8a0b
commit
f625e3beb5
|
@ -20,5 +20,6 @@ GetKnowhereMetrics() {
|
|||
auto len = str.length();
|
||||
char* res = (char*)malloc(len + 1);
|
||||
memcpy(res, str.data(), len);
|
||||
res[len] = '\0';
|
||||
return res;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue