[Bug 216633] x11/slim: fails to build with clang 4.0

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Tue Jan 31 01:50:57 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=216633

Henry Hu <henry.hu.sh at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #179453|                            |maintainer-approval+
              Flags|                            |

--- Comment #1 from Henry Hu <henry.hu.sh at gmail.com> ---
Created attachment 179453
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=179453&action=edit
patch to fix build

I don't have clang 4.0 for now, so I can't test it, but this patch should work.
Honestly, I think that this check should be removed. From Xlib.h:
/*
 * Graphics context.  The contents of this structure are implementation
 * dependent.  A GC should be treated as opaque by application code.
 */
XCreateGC's man page does not mention what the return value would be if it
failed, and after checking 10 pages of github search results, no one checked
the return value of XCreateGC.
However, given that GC is a pointer, checking it against NULL should serve the
purpose.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-ports-bugs mailing list