Code clean, remove unnecessary condition and fix var type.
Signed-off-by: Jaeyun <jy1210.jung@samsung.com>
/* Stop and clear the message thread. */
if (conn->msg_thread) {
- if (conn->running) {
- conn->running = false;
- }
+ conn->running = false;
pthread_join (conn->msg_thread, NULL);
conn->msg_thread = 0;
}
}
if (eh->listener_thread) {
- if (eh->listening) {
- eh->listening = false;
- }
-
+ eh->listening = false;
pthread_join (eh->listener_thread, NULL);
eh->listener_thread = 0;
}
nns_edge_metadata_s *meta;
nns_edge_metadata_node_s *node;
char *serialized, *ptr;
- nns_size_t total;
- uint32_t len;
+ nns_size_t total, len;
meta = (nns_edge_metadata_s *) metadata_h;
if (meta->list_len == 0)
return NNS_EDGE_ERROR_NONE;
+ /* length, # of metadata */
total = len = sizeof (uint32_t);
node = meta->list;