Rollback 10/4810/4
authorsjana <sj492a@att.com>
Tue, 6 Oct 2020 21:29:57 +0000 (17:29 -0400)
committerswc <sw94.chung@samsung.com>
Wed, 14 Oct 2020 01:54:32 +0000 (10:54 +0900)
-rollbacked to master branch
-changed msgs_proc.cc
 -me_id receiving method

Issue-ID: RICAPP-148

Signed-off-by: swc <sw94.chung@samsung.com>
Change-Id: I5bf2d3bfff3c6e78b10bdaf99399ddb260d8de55

src/xapp-mgmt/msgs_proc.cc

index 767ef27..06cc81a 100644 (file)
@@ -151,7 +151,6 @@ void XappMsgHandler::operator()(rmr_mbuf_t *message, bool *resend){
        }
        a1_policy_helper helper;
        bool res=false;
-       std::string str_meid;
        switch(message->mtype){
                //need to fix the health check.
                case (RIC_HEALTH_CHECK_REQ):
@@ -170,10 +169,13 @@ void XappMsgHandler::operator()(rmr_mbuf_t *message, bool *resend){
                                } else {
                                        rmr_get_meid(message, me_id);
                                }
+                               if(me_id == NULL){
+                                       mdclog_write(MDCLOG_ERR, " Error :: %s, %d : rmr_get_meid failed me_id is NULL", __FILE__, __LINE__);
+                                       break;
+                               }
                                mdclog_write(MDCLOG_INFO,"RMR Received MEID: %s",me_id);
-                               str_meid.insert(0,(char*)me_id);
                                if(_ref_sub_handler !=NULL){
-                                       _ref_sub_handler->manage_subscription_response(message->mtype, str_meid);
+                                       _ref_sub_handler->manage_subscription_response(message->mtype, reinterpret_cast< char const* >(me_id));
                                } else {
                                        mdclog_write(MDCLOG_ERR, " Error :: %s, %d : Subscription handler not assigned in message processor !", __FILE__, __LINE__);
                                }