From 50b8a12382b2a74c9596ad0fa31c1c545c0372bc Mon Sep 17 00:00:00 2001 From: vivek-shankar Date: Fri, 27 Jan 2017 22:57:56 -0500 Subject: [PATCH] escaping msgs debug --- src/buzz_update.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/buzz_update.cpp b/src/buzz_update.cpp index 037da1a..df8d260 100644 --- a/src/buzz_update.cpp +++ b/src/buzz_update.cpp @@ -173,8 +173,10 @@ memcpy(updater->inmsg_queue->queue, msg, size); void code_message_inqueue_process(){ int size=0; if(*(int*)updater->mode==CODE_RUNNING){ - if(*(uint16_t*)(updater->inmsg_queue->queue+size) > *(uint16_t*) updater->update_no){ - uint16_t update_no=*(uint16_t*)(updater->inmsg_queue->queue+size); + fprintf(stdout,"[debug]Inside inmsg code running"); + if( (*(uint16_t*)(updater->inmsg_queue->queue)) > (*(uint16_t*) updater->update_no) ){ + fprintf(stdout,"[debug]Inside update number comparision"); + uint16_t update_no=*(uint16_t*)(updater->inmsg_queue->queue); size +=sizeof(uint16_t); uint16_t update_bcode_size =*(uint16_t*)(updater->inmsg_queue->queue+size); size +=sizeof(uint16_t);