Bug 202581

Summary: Fix security/obfsclient build with clang 3.7.0
Product: Ports & Packages Reporter: Dimitry Andric <dim>
Component: Individual Port(s)Assignee: Xin LI <delphij>
Status: Closed FIXED    
Severity: Affects Some People CC: delphij, fk
Priority: --- Flags: fk: maintainer-feedback+
Version: Latest   
Hardware: Any   
OS: Any   
Bug Depends on:    
Bug Blocks: 201377    
Attachments:
Description Flags
Fix pessimizing moves in security/obfsclient none

Description Dimitry Andric freebsd_committer freebsd_triage 2015-08-22 22:50:23 UTC
Created attachment 160230 [details]
Fix pessimizing moves in security/obfsclient

diffs/security__obfsclient-fix-pessimizing-moves-1.diff
Comment 1 Dimitry Andric freebsd_committer freebsd_triage 2015-08-22 22:53:22 UTC
During the exp-run in bug 201377, it was found that security/obfsclient gives errors with a recent clang 3.7.0 snapshot:

http://package18.nyi.freebsd.org/data/headi386PR201377-default/2015-07-31_12h04m22s/logs/errors/obfsclient-0.0.2_1.log

This is because the program calls std::move() in a few situations where it is detrimental to performance, because moving a temporary object prevents copy elision.  The attached patch removes those std::move() calls.
Comment 2 Fabian Keil 2015-08-25 10:46:00 UTC
Thanks a lot for the report and the patch which I hereby approve.
Comment 3 Xin LI freebsd_committer freebsd_triage 2015-08-26 00:23:52 UTC
Committed, thanks!
Comment 4 commit-hook freebsd_committer freebsd_triage 2015-08-26 00:24:12 UTC
A commit references this bug:

Author: delphij
Date: Wed Aug 26 00:23:40 UTC 2015
New revision: 395327
URL: https://svnweb.freebsd.org/changeset/ports/395327

Log:
  Fix security/obfsclient build with clang 3.7.0.

  PR:		ports/202581
  Submitted by:	dim

Changes:
  head/security/obfsclient/Makefile
  head/security/obfsclient/files/patch-ext-easylogging++.h