[Bug 229888] devel/boost-libs: Fix undefined behavior in boost::filesystem::copy

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Thu Jul 19 15:07:29 UTC 2018


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

            Bug ID: 229888
           Summary: devel/boost-libs: Fix undefined behavior in
                    boost::filesystem::copy
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: office at FreeBSD.org
          Reporter: grembo at FreeBSD.org
          Assignee: office at FreeBSD.org
             Flags: maintainer-feedback?(office at FreeBSD.org)
 Attachment #195277 maintainer-approval?
             Flags:
             Flags: maintainer-feedback?

Created attachment 195277
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=195277&action=edit
Fix to boost::filesystem::copy

There is a bug in boost::filesystem::copy that leads to undefined behavior (and
segfault on 11.2 + clang6 + stackprotector support).

Example:

int main()
{
  boost::system::error_code ec;
  boost::filesystem::copy("/tmp/t.pdf", "/tmp/t2.pdf", ec);
}

This is caused by derefencing null pointers.

There is already a pull request on github:

https://github.com/boostorg/filesystem/pull/71

This patch pulls in this patch (tested) and fixes the issue. The same code
worked on 10.3 with clang 3.9 (at least on an older ports tree), that's why
this is a ticking time bomb for people upgrading to 11.2.

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


More information about the freebsd-office mailing list