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/11/28 15:00:34 UTC

[GitHub] [nuttx] sdc-g opened a new pull request, #7723: meminfo: buflen identify the left of buffer

sdc-g opened a new pull request, #7723:
URL: https://github.com/apache/nuttx/pull/7723

   ## Summary
   It is enought to only checking the buflen's avaiable or not. (total size means total copied size)
   ## Impact
   
   ## Testing
   
   


-- 
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] [nuttx] xiaoxiang781216 commented on pull request #7723: meminfo: buflen identify the left of buffer

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 commented on PR #7723:
URL: https://github.com/apache/nuttx/pull/7723#issuecomment-1329290711

   @sdc-g please squash the change into one patch with:
   git rebase --interactive HEAD~4
   change pick to squash for the last commit
   git push -f origin


-- 
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] [nuttx] xiaoxiang781216 merged pull request #7723: meminfo: buflen identify the left of buffer

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


-- 
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] [nuttx] pkarashchenko commented on a diff in pull request #7723: meminfo: buflen identify the left of buffer

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


##########
fs/procfs/fs_procfsmeminfo.c:
##########
@@ -328,7 +328,7 @@ static ssize_t meminfo_read(FAR struct file *filep, FAR char *buffer,
     }
 
 #ifdef CONFIG_MM_PGALLOC
-  if (totalsize < buflen)
+  if (buflen)

Review Comment:
   ```suggestion
     if (buflen > 0)
   ```
   



##########
fs/procfs/fs_procfsmeminfo.c:
##########
@@ -359,7 +359,7 @@ static ssize_t meminfo_read(FAR struct file *filep, FAR char *buffer,
 #endif
 
 #if defined(CONFIG_ARCH_HAVE_PROGMEM) && defined(CONFIG_FS_PROCFS_INCLUDE_PROGMEM)
-  if (totalsize < buflen)
+  if (buflen)

Review Comment:
   ```suggestion
     if (buflen > 0)
   ```
   



##########
fs/procfs/fs_procfsmeminfo.c:
##########
@@ -302,7 +302,7 @@ static ssize_t meminfo_read(FAR struct file *filep, FAR char *buffer,
 
   for (entry = g_procfs_meminfo; entry != NULL; entry = entry->next)
     {
-      if (totalsize < buflen)
+      if (buflen)

Review Comment:
   ```suggestion
         if (buflen > 0)
   ```
   



-- 
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] [nuttx] sdc-g commented on pull request #7723: meminfo: buflen identify the left of buffer

Posted by GitBox <gi...@apache.org>.
sdc-g commented on PR #7723:
URL: https://github.com/apache/nuttx/pull/7723#issuecomment-1329306900

   > @sdc-g please squash the change into one patch with: git rebase --interactive HEAD~4 change pick to squash for the last commit git push -f origin
   
   @xiaoxiang781216 thanks, updated.


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