Bug 229376

Summary: [PATCH] devel/avarice: unbreak build under 11.2-RELEASE (and clang 6)
Product: Ports & Packages Reporter: Craig Leres <leres>
Component: Individual Port(s)Assignee: Joerg Wunsch <joerg>
Status: Closed FIXED    
Severity: Affects Only Me Flags: bugzilla: maintainer-feedback? (joerg)
Priority: ---    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
patch leres: maintainer-approval?

Description Craig Leres freebsd_committer 2018-06-27 22:00:20 UTC
After upgrading to 11.2-RELEASE devel/avarice fails to compile with:

    jtagrw.cc:134:13: error: cannot initialize return object of type 'uchar *' (aka 'unsigned char *') with an rvalue of type 'bool'
                return false;
                       ^~~~~

examination of the code shows another case with a similar check that returns NULL.

I also filed an upstream bug report:

    https://sourceforge.net/p/avarice/bugs/24/
Comment 1 Craig Leres freebsd_committer 2018-06-27 22:01:46 UTC
Created attachment 194695 [details]
patch
Comment 2 Joerg Wunsch freebsd_committer 2018-07-08 17:58:10 UTC
Thanks for the patch!

Patch approved by maintainer.
Comment 3 commit-hook freebsd_committer 2018-07-08 22:35:38 UTC
A commit references this bug:

Author: leres
Date: Sun Jul  8 22:34:54 UTC 2018
New revision: 474207
URL: https://svnweb.freebsd.org/changeset/ports/474207

Log:
  After upgrading to 11.2-RELEASE devel/avarice fails to
  compile with:

      jtagrw.cc:134:13: error: cannot initialize return object of type 'uchar *' (aka 'unsigned char *') with an rvalue of type 'bool'

  		return false;
  		       ^~~~~

  examination of the code shows another case with a similar
  check that returns NULL.

  I also filed an upstream bug report:

      https://sourceforge.net/p/avarice/bugs/24/

  PR:		229376
  Reviewed by:	ler (mentor)
  Approved by:	joerg (maintainer), ler (mentor)
  Differential Revision:	https://reviews.freebsd.org/D16184

Changes:
  head/devel/avarice/Makefile
  head/devel/avarice/files/
  head/devel/avarice/files/patch-src_jtagrw.cc