派生自 development/c++

chenshijun
2019-02-20 f54c3b20dc82df32c4314d2c27aa2eb1fead6312
QiaoJiaSystem/DataManagerServer/http_configserver.cpp
@@ -951,8 +951,10 @@
void devHttpServer_c::killVideoAnalysFromHCApp() const {
    string local_passwd = appConfig.getStringProperty("localPasswd");
    string cmd_kill = "echo \"" + local_passwd + "\" | sudo -S pkill -9 VideoAnalysFrom";
    system(cmd_kill.c_str());
    string cmd_kill_VideoAnalys = "echo \"" + local_passwd + "\" | sudo -S pkill -9 VideoAnalys";
    system(cmd_kill_VideoAnalys.c_str());
    string cmd_kill_VideoToIma = "echo \"" + local_passwd + "\" | sudo -S pkill -9 VideoToIma";
    system(cmd_kill_VideoToIma.c_str());
    DBG("system(\"sudo -S pkill -9 VideoAnalysFromHC\");");
}
@@ -2078,6 +2080,12 @@
                    img_str.append(fdfsClient.fastFds->getIp() + "/").append(img_tmp);
                    img_url.swap(img_str);
                }
            } else {
                std::string img_str = "http://";
                if (fdfsClient.fastFds != nullptr) {
                    img_str.append(fdfsClient.fastFds->getIp() + "/").append(img_url);
                    img_url.swap(img_str);
                }
            }
            auto t_results = m_curlDownloadImg.download_jpeg(const_cast<char *>(img_url.c_str()));
@@ -2528,7 +2536,7 @@
            std::string picDate = value["picDate"].asString();
            std::string imgKey = value["imgKey"].asString();
            //兼容旧版本
            if(imgKey=="undefined")
            if(imgKey=="undefined" || imgKey.empty())
            {
                return getAlarmImageByPicDateAndDevId(picDate,devId,response);
            }   
@@ -2644,7 +2652,7 @@
        std::string path;
        //兼容旧版本
        if(imgKey=="undefined")
        if(imgKey=="undefined"||imgKey.empty())
        {
            qint64 sub;
            path = getVideoPathByPicDate(picDate,devId,sub);