增加网络拍照失败日志

rtmpsuck
XI.CHEN 5 months ago
parent 9417980864
commit 5d318b62c8

@ -58,8 +58,7 @@ size_t GpioControl::turnOnImpl(const IOT_PARAM& param)
}
if (it == m_items.end())
{
ITEM item = {param.cmd, references, 0, 0, 0};
item.openTime = now;
ITEM item = {param.cmd, references, 0, 0, now};
m_items.push_back(item);
SetCamerastatus(param.cmd, true);
}

@ -1622,7 +1622,7 @@ bool CPhoneDevice::TakePhotoWithNetCamera(IDevice::PHOTO_INFO& localPhotoInfo, c
}
else
{
XYLOG(XYLOG_SEVERITY_ERROR, "Faile to TP on NET Camera CH=%u PR=%X PHOTOID=%u URL=http://%s%s", (uint32_t)localPhotoInfo.channel, (uint32_t)localPhotoInfo.preset,
XYLOG(XYLOG_SEVERITY_ERROR, "Failed to TP on NET Camera CH=%u PR=%X PHOTOID=%u URL=http://%s%s", (uint32_t)localPhotoInfo.channel, (uint32_t)localPhotoInfo.preset,
localPhotoInfo.photoId, netPhotoInfo.ip, netPhotoInfo.url);
TakePhotoCb(0, localPhotoInfo, "", 0);
}

@ -97,6 +97,7 @@ int DoGetRequest(const char* url, int authType, const char* userName, const char
}
else
{
XYLOG(XYLOG_SEVERITY_WARNING, "Net Photo failure, nRet=%s", nRet);
printf("GET err=%d", nRet);
}
curl_easy_cleanup(curl);
@ -137,6 +138,9 @@ int DoPutRequest(const char* url, int authType, const char* userName, const char
curl_easy_setopt(curl, CURLOPT_SOCKOPTDATA, &netHandle);
}
if(contents != NULL)
curl_easy_setopt(curl, CURLOPT_POSTFIELDS, contents);
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, OnWriteData);
// 设置回调函数的参数,获取反馈信息
curl_easy_setopt(curl, CURLOPT_WRITEDATA, &data);

@ -10,6 +10,7 @@
#include <bits/ioctl.h>
#include <android/multinetwork.h>
#include "LogThread.h"
#ifndef __HTTP_CLIENT__
#define __HTTP_CLIENT__

Loading…
Cancel
Save