fix unit test case that causes core dump
This commit is contained in:
parent
49dc204076
commit
a01f1a4e1d
|
@ -236,8 +236,12 @@ static int32_t dmSpawnUdfd(SDnode *pDnode) {
|
||||||
uv_process_options_t options = {0};
|
uv_process_options_t options = {0};
|
||||||
|
|
||||||
char path[PATH_MAX] = {0};
|
char path[PATH_MAX] = {0};
|
||||||
strncpy(path, tsProcPath, strlen(tsProcPath));
|
if (tsProcPath == NULL) {
|
||||||
char* dirName = taosDirName(path);
|
path[0] = '.';
|
||||||
|
} else {
|
||||||
|
strncpy(path, tsProcPath, strlen(tsProcPath));
|
||||||
|
taosDirName(path);
|
||||||
|
}
|
||||||
strcat(path, "/udfd");
|
strcat(path, "/udfd");
|
||||||
char* argsUdfd[] = {path, "-c", configDir, NULL};
|
char* argsUdfd[] = {path, "-c", configDir, NULL};
|
||||||
options.args = argsUdfd;
|
options.args = argsUdfd;
|
||||||
|
|
Loading…
Reference in New Issue