cederom commented on code in PR #3117:
URL: https://github.com/apache/nuttx-apps/pull/3117#discussion_r2179922286


##########
system/nxplayer/nxplayer.c:
##########
@@ -221,18 +220,35 @@ static int _open_with_http(const char *fullurl)
 
   FAR struct hostent *he;
   he = gethostbyname(hostname);
+  if (!he)
+    {
+      close(s);
+      return -ENETUNREACH; /* DNS resolution failed */
+    }
 
   memcpy(&server.sin_addr.s_addr,
          he->h_addr, sizeof(in_addr_t));
-

Review Comment:
   these blank lines increase readability we can leave them untouched :-)



-- 
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-unsubscr...@nuttx.apache.org

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

Reply via email to