gustavonihei commented on a change in pull request #695:
URL: 
https://github.com/apache/incubator-nuttx-apps/pull/695#discussion_r622259139



##########
File path: include/netutils/webclient.h
##########
@@ -249,6 +277,19 @@ struct webclient_context
   unsigned int http_status;
   FAR char *http_reason;
   size_t http_reason_len;
+
+  struct wget_s *ws;
+};
+
+struct webclient_poll_info
+{
+  /* A file descriptor to wait for i/o. */
+
+  int fd;
+  unsigned int flags; /* OR'ed WEBCLIENT_POLL_INFO_xxx flags */
+
+#define        WEBCLIENT_POLL_INFO_WANT_READ   1U
+#define        WEBCLIENT_POLL_INFO_WANT_WRITE  2U

Review comment:
       Placement of these preprocessor definitions is not compliant to the 
coding standard.

##########
File path: netutils/webclient/webclient.c
##########
@@ -132,6 +129,37 @@
  * Private Types
  ****************************************************************************/
 
+enum webclient_state
+  {
+    WEBCLIENT_STATE_SOCKET,
+    WEBCLIENT_STATE_CONNECT,
+    WEBCLIENT_STATE_PREPARE_REQUEST,
+    WEBCLIENT_STATE_SEND_REQUEST,
+    WEBCLIENT_STATE_SEND_REQUEST_BODY,
+    WEBCLIENT_STATE_STATUSLINE,
+    WEBCLIENT_STATE_HEADERS,
+    WEBCLIENT_STATE_DATA,
+    WEBCLIENT_STATE_CLOSE,
+    WEBCLIENT_STATE_DONE,
+  };
+
+struct conn
+{
+  bool tls;
+
+  /* for !tls */
+
+  int sockfd;
+  unsigned int flags;
+
+#define CONN_WANT_READ  WEBCLIENT_POLL_INFO_WANT_READ
+#define CONN_WANT_WRITE WEBCLIENT_POLL_INFO_WANT_WRITE

Review comment:
       Placement of these preprocessor definitions is not compliant to the 
coding standard.




-- 
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:
[email protected]


Reply via email to