You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2022/08/23 09:17:18 UTC

[GitHub] [incubator-nuttx] chengkai15 opened a new pull request, #6898: libc: add lib_dump utils

chengkai15 opened a new pull request, #6898:
URL: https://github.com/apache/incubator-nuttx/pull/6898

   Signed-off-by: chengkai <ch...@xiaomi.com>
   
   ## Summary
   add some lib_dump  debug api  
   1. void lib_dumphandler(FAR const char *msg, FAR const uint8_t *buffer,
                        unsigned int buflen, lib_dump_handler_t handler,
                        FAR void *arg);
   2. void lib_dumpvhandler(FAR const char *msg, FAR const struct iovec *iov,
                         int iovcnt, lib_dump_handler_t handler,
                         FAR void *arg);
   3.  void lib_dumpfile(int fd, FAR const char *msg, FAR const uint8_t *buffer,
                     unsigned int buflen);
   4. void lib_dumpvfile(int fd, FAR const char *msg, FAR const struct iovec *iov,
                      int iovcnt);               
                          
   ## Impact
   lib_dumpvbuffer api
   
   ## Testing
   pass ci
   
   


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


[GitHub] [incubator-nuttx] pkarashchenko commented on a diff in pull request #6898: libc: add lib_dump utils

Posted by GitBox <gi...@apache.org>.
pkarashchenko commented on code in PR #6898:
URL: https://github.com/apache/incubator-nuttx/pull/6898#discussion_r952716843


##########
libs/libc/misc/lib_dumpbuffer.c:
##########
@@ -32,6 +32,27 @@
  * Public Functions
  ****************************************************************************/
 
+/****************************************************************************
+ * Name: lib_dumphandler
+ *
+ * Description:
+ *  Do a pretty buffer dump with handler output.
+ *
+ ****************************************************************************/
+
+void lib_dumphandler(FAR const char *msg, FAR const uint8_t *buffer,
+                     unsigned int buflen, lib_dump_handler_t handler,
+                     FAR void *arg)
+{
+  struct iovec buf =
+    {
+      .iov_base = (FAR char *)buffer,
+      .iov_len = buflen,

Review Comment:
   ```suggestion
         (FAR char *)buffer,
         buflen,
   ```



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


[GitHub] [incubator-nuttx] xiaoxiang781216 merged pull request #6898: libc: add lib_dump utils

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 merged PR #6898:
URL: https://github.com/apache/incubator-nuttx/pull/6898


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


[GitHub] [incubator-nuttx] chengkai15 commented on a diff in pull request #6898: libc: add lib_dump utils

Posted by GitBox <gi...@apache.org>.
chengkai15 commented on code in PR #6898:
URL: https://github.com/apache/incubator-nuttx/pull/6898#discussion_r953301516


##########
libs/libc/misc/lib_dumpbuffer.c:
##########
@@ -32,6 +32,27 @@
  * Public Functions
  ****************************************************************************/
 
+/****************************************************************************
+ * Name: lib_dumphandler
+ *
+ * Description:
+ *  Do a pretty buffer dump with handler output.
+ *
+ ****************************************************************************/
+
+void lib_dumphandler(FAR const char *msg, FAR const uint8_t *buffer,
+                     unsigned int buflen, lib_dump_handler_t handler,
+                     FAR void *arg)
+{
+  struct iovec buf =
+    {
+      .iov_base = (FAR char *)buffer,
+      .iov_len = buflen,

Review Comment:
   done



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