1. 返回合适的错误标识
This commit is contained in:
@@ -60,6 +60,8 @@ char *CheckTimeRegionWithMonth(void *PtrHIKNvr, int year, int month) {
|
||||
|
||||
if (nRet == 0) {
|
||||
res = HIKNvrObj->TimeToJson(select_time, &available_date_vec).dump();
|
||||
}else{
|
||||
res = "";
|
||||
}
|
||||
char *cString = new char[res.size() + 1];
|
||||
std::strcpy(cString, res.c_str());
|
||||
@@ -77,6 +79,8 @@ char *CheckTimeRegionWithDay(void *PtrHIKNvr, int year, int month, int day) {
|
||||
int nRet = HIKNvrObj->CheckTimeRegionWithDay(select_time, available_time_vec);
|
||||
if (nRet == 0) {
|
||||
res = HIKNvrObj->TimeToJsonInDay(select_time, &available_time_vec).dump();
|
||||
}else{
|
||||
res = "";
|
||||
}
|
||||
char *cString = new char[res.size() + 1];
|
||||
std::strcpy(cString, res.c_str());
|
||||
|
||||
Reference in New Issue
Block a user