Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 08 Jan 2015 19:31:54 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 196622] vm_map.h defines "min_offset" and "max_offset" which causes namespace pollution.
Message-ID:  <bug-196622-8@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=196622

            Bug ID: 196622
           Summary: vm_map.h defines "min_offset" and "max_offset" which
                    causes namespace pollution.
           Product: Base System
           Version: 11.0-CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: kern
          Assignee: freebsd-bugs@FreeBSD.org
          Reporter: tjj5036@gmail.com

Created attachment 151507
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=151507&action=edit
A patch to fix the issue

In vm_map.h, there is a struct called vm_map that has two members named
min_offset and max_offset respectively. There are macros that define these two
to header.start and header.end respectively. Unfortunately, if you include
vm_map.h anywhere, it causes issues with anything also declared to be min_/max_
offset. ZFS actually undefines them. This fix would remove the defines, making
it so you can include the header safely without fear of unexpected bugs.

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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-196622-8>