mirror of
https://github.com/Ascend/ascend-docker-runtime.git
synced 2025-10-10 14:10:08 +08:00
Match-id-f7cdfc7a411976f9681dbea6a0d794378ec36d97
This commit is contained in:
@@ -201,12 +201,6 @@ int DoPrepare(const struct CmdArgs *args, struct ParsedConfig *config)
|
||||
return -1;
|
||||
}
|
||||
|
||||
ret = ParseRuntimeOptions(args->options);
|
||||
if (ret < 0) {
|
||||
LogError("error: failed to parse runtime options.");
|
||||
return -1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -277,11 +271,34 @@ int Process(int argc, char **argv)
|
||||
return -1;
|
||||
}
|
||||
|
||||
ret = ParseRuntimeOptions(args.options);
|
||||
if (ret < 0) {
|
||||
LogError("error: failed to parse runtime options.");
|
||||
return -1;
|
||||
}
|
||||
|
||||
SetPidForLog(args.pid);
|
||||
|
||||
if (IsOptionVerboseSet()) {
|
||||
ret = OpenLog(DEFAULT_LOG_FILE);
|
||||
if (ret < 0) {
|
||||
LogError("error: failed to open log file %s.", DEFAULT_LOG_FILE);
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
ret = SetupContainer(&args);
|
||||
if (ret < 0) {
|
||||
if (IsOptionVerboseSet()) {
|
||||
CloseLog();
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (IsOptionVerboseSet()) {
|
||||
CloseLog();
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user