Memory Leak Reduction
diff --git a/nlsr_npt.c b/nlsr_npt.c
index 8a04ff0..48577cb 100644
--- a/nlsr_npt.c
+++ b/nlsr_npt.c
@@ -51,7 +51,7 @@
ne->orig_router=(char *)malloc(strlen(orig_router)+1);
memset(ne->orig_router,0,strlen(orig_router)+1);
- memcpy(ne->orig_router,orig_router,strlen(orig_router));
+ memcpy(ne->orig_router,orig_router,strlen(orig_router)+1);
@@ -633,7 +633,7 @@
printf("Face Not Found \n");
if ( nlsr->detailed_logging )
writeLogg(__FILE__,__FUNCTION__,__LINE__,"Face Not Found \n");
- struct face_list_entry *fle=(struct face_list_entry *)malloc(sizeof(struct face_list_entry));
+ struct face_list_entry *fle;//=(struct face_list_entry *)malloc(sizeof(struct face_list_entry));
fle=ef->data;
fle->next_hop_face=face_id;
fle->route_cost=route_cost;