[Bug 244235] x11/xkbcomp: Fix build with clang 10.0.0

[email protected]
Newsgroups gmane.os.freebsd.devel.x11
Message-ID <[email protected]/bugzilla/>
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=244235

            Bug ID: 244235
           Summary: x11/xkbcomp: Fix build with clang 10.0.0
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: Individual Port(s)
          Assignee: [email protected]
          Reporter: [email protected]
          Assignee: [email protected]
             Flags: maintainer-feedback?([email protected])

Created attachment 211766
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=211766&action=edit
Use strcmp instead of custom macros

Fix clang 10.0.0 errors:

xkbcomp.c:228:37: error: result of comparison against a string literal is
unspecified (use an explicit string comparison function instead)
[-Werror,-Wstring-compare]
        if ((argv[i][0] != '-') || (uStringEqual(argv[i], "-")))
                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
./utils.h:195:30: note: expanded from macro 'uStringEqual'
#define uStringEqual(s1,s2)     (uStringCompare(s1,s2)==Equal)
                                 ^~~~~~~~~~~~~~~~~~~~~
./utils.h:198:38: note: expanded from macro 'uStringCompare'
                                 (s1)!=(s2):strcmp(s1,s2))
                                     ^ ~~~~

Don't attempt to do this macro trickery, and simply use strcmp instead,
where it applies.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[email protected]"
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.