This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/53457] New: Accommodate non-compliant ioctl() on VxWorks


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53457

             Bug #: 53457
           Summary: Accommodate non-compliant ioctl() on VxWorks
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: rbmj@verizon.net
                CC: rbmj@verizon.net
              Host: x86_64-linux-gnu
            Target: powerpc-wrs-vxworks
             Build: x86_64-linux-gnu


Created attachment 27480
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=27480
Patch

On VxWorks, ioctl()'s third argument is of type int, so this added
macro wraps over ioctl to cast the third argument to an integer.
This *cannot* be in config/os/vxworks/os_defines.h as otherwise
the function prototype will trigger the macro and it will be ugly.

Alternate solution is to #ifdef at the call site.

Attached patch is against trunk.  Without it the compile fails because VxWorks
ioctl() requires third argument to be of type int, and C++ doesn't allow
implicit conversion from pointer to integer.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]