You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by gn...@apache.org on 2020/05/03 14:17:46 UTC

[incubator-nuttx] branch master updated (6204e10 -> f09e58f)

This is an automated email from the ASF dual-hosted git repository.

gnutt pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git.


    from 6204e10  x86_64: Add nsh configuration with procfs bringup
     new 4e7d59f  Fix debug assert in ioctl to check if int will fit in  unsigned long not be unsigned long
     new f09e58f  Update libs/libc/misc/lib_ioctl.c

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 libs/libc/misc/lib_ioctl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


[incubator-nuttx] 01/02: Fix debug assert in ioctl to check if int will fit in unsigned long not be unsigned long

Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

gnutt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit 4e7d59f6bcb770202f27fb5787274771fdd37b44
Author: Brennan Ashton <ba...@brennanashton.com>
AuthorDate: Sat May 2 20:25:35 2020 -0700

    Fix debug assert in ioctl to check if int will fit in
     unsigned long not be unsigned long
    
    Signed-off-by: Brennan Ashton <ba...@brennanashton.com>
---
 libs/libc/misc/lib_ioctl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libs/libc/misc/lib_ioctl.c b/libs/libc/misc/lib_ioctl.c
index 20127ef..2485a6a 100644
--- a/libs/libc/misc/lib_ioctl.c
+++ b/libs/libc/misc/lib_ioctl.c
@@ -91,7 +91,7 @@ int ioctl(int fd, int req, ...)
   /* Get the unsigned long argument.
    *
    * REVISIT:  This could be the cause of the crash down the road if the
-   * actual size of the argument is anything other than sizeof(unsigned long).
+   * actual size of the argument not sizeof(unsigned long).
    * Most small integers will be promoted to 'int'.  ARM should pass the
    * following test with all three types having sizeof(type) == 4 bytes.
    * 'float' should also be tested.  But 'long long' and 'double' are out of
@@ -102,7 +102,7 @@ int ioctl(int fd, int req, ...)
    * discover cases where something worse happens!
    */
 
-  DEBUGASSERT(sizeof(int)        == sizeof(unsigned long) &&
+  DEBUGASSERT(sizeof(int)        <= sizeof(unsigned long) &&
               sizeof(FAR void *) == sizeof(unsigned long));
 
   va_start(ap, req);


[incubator-nuttx] 02/02: Update libs/libc/misc/lib_ioctl.c

Posted by gn...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

gnutt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit f09e58fe73a5f47c7d88060e942c983c04f2116b
Author: patacongo <sp...@yahoo.com>
AuthorDate: Sun May 3 07:48:32 2020 -0600

    Update libs/libc/misc/lib_ioctl.c
---
 libs/libc/misc/lib_ioctl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libs/libc/misc/lib_ioctl.c b/libs/libc/misc/lib_ioctl.c
index 2485a6a..af91bca 100644
--- a/libs/libc/misc/lib_ioctl.c
+++ b/libs/libc/misc/lib_ioctl.c
@@ -91,7 +91,7 @@ int ioctl(int fd, int req, ...)
   /* Get the unsigned long argument.
    *
    * REVISIT:  This could be the cause of the crash down the road if the
-   * actual size of the argument not sizeof(unsigned long).
+   * actual size of the argument is not sizeof(unsigned long).
    * Most small integers will be promoted to 'int'.  ARM should pass the
    * following test with all three types having sizeof(type) == 4 bytes.
    * 'float' should also be tested.  But 'long long' and 'double' are out of