Skip to content
Snippets Groups Projects
  1. Oct 08, 2015
  2. Oct 07, 2015
  3. Oct 06, 2015
  4. Sep 23, 2015
    • Arseny Kapoulkine's avatar
      scripts: Enable C++11 in CMakeLists · 2cda0533
      Arseny Kapoulkine authored
      We now make sure that in CMake builds we have long long support. This requires
      CMake 3.1 for target_compile_features.
      
      Fixes #53 (as long as packages use this CMake script... most of them do)
      2cda0533
  5. Sep 21, 2015
  6. Sep 20, 2015
  7. Sep 19, 2015
  8. Aug 25, 2015
  9. Aug 14, 2015
  10. Jul 27, 2015
    • Arseny Kapoulkine's avatar
      Fix two UB sanitizer false positives · f738675f
      Arseny Kapoulkine authored
      Change the expression to reference the array element indirectly. The memory
      block can be bigger than the structure so it's invalid to use static data[]
      size for bounds checking.
      f738675f
  11. Jul 25, 2015
    • Arseny Kapoulkine's avatar
      XPath: Increase memory block alignment to 8 bytes · bd7a8fa4
      Arseny Kapoulkine authored
      To be more precise, the memory block is now aligned to be able to reliably
      allocate objects with both double and pointer fields. If there is a platform
      with a 4-byte double and a 4-byte pointer, the memory block alignment there will
      stay the same after this change.
      
      Fixes #48.
      bd7a8fa4
    • Arseny Kapoulkine's avatar
      tests: Fix test allocator to provide fundamental alignment · e8fdd130
      Arseny Kapoulkine authored
      Previously test allocator only guaranteed alignment enough for a pointer.
      
      On some platforms (e.g. SPARC) double has to be aligned to 8 bytes but pointers
      can have a size of 4 bytes. This commit increases allocation header to fix that.
      
      In practical terms the allocation header is now always 8 bytes.
      e8fdd130
    • Arseny Kapoulkine's avatar
      XPath: Refactor block allocation · 66f242a4
      Arseny Kapoulkine authored
      Extract memory page size and block alignment into named constants.
      66f242a4
    • Arseny Kapoulkine's avatar
      tests: Only enable page heap on x86/x64 · a562bf6d
      Arseny Kapoulkine authored
      This fixes tests in PUGIXML_NO_XPATH mode on SPARC64 (#48).
      
      SPARC does not allow unaligned accesses - e.g. you can't read an unaligned int.
      Normally pugixml does not perform unaligned integer/pointer accesses, but page
      heap can allocate blocks that are not aligned so that we can detect a single-
      byte read/write overrun.
      
      Additionally, the hardcoded page size we're currently using is really system
      specific - on SPARC the page size can be 8 Kb instead of 4 Kb so mprotect can
      fail.
      a562bf6d
  12. Jul 23, 2015
  13. Jun 24, 2015
  14. Jun 13, 2015
    • Arseny Kapoulkine's avatar
      Makefile now supports Xcode 7 ASAN · 238b786b
      Arseny Kapoulkine authored
      All other sanitizers are still unavailable so only enable them on non-OSX
      systems.
      238b786b
    • Arseny Kapoulkine's avatar
      Fix Clang 3.7 compatibility · d04df2a4
      Arseny Kapoulkine authored
      Apparently Clang 3.7 implements C++ DR 1748 that makes placement new with null
      pointer undefined behavior. Which renders all C++ programs that rely on this
      invalid. Which includes pugixml.
      
      This is not very likely to happen in the wild because the allocations that are
      subject to this in pugixml are relatively small, but tests break because of
      this.
      
      Fix the issue by adding null pointer checks (that are completely redundant in
      all current compilers except Clang 3.7 but it's not like there is another
      option).
      d04df2a4
Loading