You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "xiaoxiang781216 (via GitHub)" <gi...@apache.org> on 2023/08/19 10:33:48 UTC

[GitHub] [nuttx] xiaoxiang781216 commented on a diff in pull request #10296: ipv6_setsockopt: remove redundant logic

xiaoxiang781216 commented on code in PR #10296:
URL: https://github.com/apache/nuttx/pull/10296#discussion_r1299169245


##########
net/inet/ipv6_setsockopt.c:
##########
@@ -86,28 +86,17 @@ int ipv6_setsockopt(FAR struct socket *psock, int option,
       /* Handle MLD-related socket options */
 
       case IPV6_JOIN_GROUP:       /* Join a multicast group */
-        {
-          FAR const struct ipv6_mreq *mrec ;
-
-          mrec = (FAR const struct ipv6_mreq *)value;
-          ret = mld_joingroup(mrec);
-        }
+        ret = mld_joingroup(value);

Review Comment:
   Both C/C++ allow any pointer type convert to void * without cast, but only C allow void * convert to other pointer type without cast.



-- 
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.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

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