utzig commented on a change in pull request #109:
URL: https://github.com/apache/mynewt-mcumgr/pull/109#discussion_r574487942



##########
File path: mgmt/src/mgmt.c
##########
@@ -74,7 +74,7 @@ mgmt_streamer_free_buf(struct mgmt_streamer *streamer, void 
*buf)
 void
 mgmt_unregister_group(struct mgmt_group *group)
 {
-    struct mgmt_group *curr = mgmt_group_list, *prev;
+    struct mgmt_group *curr = mgmt_group_list, *prev = NULL;

Review comment:
       This might fix the warning but it still could break when doing the 
`prev->mg_next = curr->mg_next;` below. I submitted a review for the original 
PR and would prefer a fix like suggested.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to