Remove memory leak from node loader temporally.
@@ -2808,6 +2808,9 @@ void node_loader_impl_thread(void * data)
return;
}
+ /* Initialize the argv string memory */
+ memset(argv_str, 0, sizeof(char) * argv_str_size);
+
memcpy(&argv_str[0], &exe_path_str[exe_path_str_offset], exe_path_str_size);
memcpy(&argv_str[exe_path_str_size], bootstrap_path_str, bootstrap_path_str_size);
memcpy(&argv_str[exe_path_str_size + bootstrap_path_str_size], node_impl_ptr_str, node_impl_ptr_str_size);
@@ -2846,6 +2849,8 @@ void node_loader_impl_thread(void * data)
}
#endif
+ /* TODO: Review this, it generates a memory leak in line with 'auxv->a_type' */
+ /*
#if defined(__linux__)
{
char** envp = environ;
@@ -2861,6 +2866,7 @@ void node_loader_impl_thread(void * data)
}
}
#endif
+ */
/* Unlock node implementation mutex */
uv_mutex_unlock(&node_impl->mutex);
