From efafab5273ba3ff13a19f07088c320a5180188b6 Mon Sep 17 00:00:00 2001
From: pans <pansen626@sina.com>
Date: 星期四, 31 一月 2019 10:49:56 +0800
Subject: [PATCH] 1.2_布控feature: Auto stash before merge of "ywv1.2_布控feature" and "origin/ywv1.2_布控feature"
---
QiaoJiaSystem/StructureApp/HiredisTool.cpp | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/QiaoJiaSystem/StructureApp/HiredisTool.cpp b/QiaoJiaSystem/StructureApp/HiredisTool.cpp
index a54a9bd..6a8715b 100644
--- a/QiaoJiaSystem/StructureApp/HiredisTool.cpp
+++ b/QiaoJiaSystem/StructureApp/HiredisTool.cpp
@@ -89,15 +89,19 @@
CvUtil::cvMat2Buffer(img,buf);
// json["time"]=info.time;
json["img"]=std::string(buf.begin(),buf.end());
- // buf.clear();
- std::string strBuf=std::string(buf.begin(),buf.end());
- if(!listLpush(file_name,json.toStyledString()));
+ if(!checkParam())
{
+ return false;
+ }
+ redisReply *reply;
+ reply = (redisReply*)redisCommand(m_redis,"lpush %s %s", file_name.c_str(),json.toStyledString().c_str());
+ if(!checkResult(reply))
+ {
return false;
}
- //DBG(json.toStyledString());
+ freeReplyObject(reply);
return true;
}
--
Gitblit v1.8.0