]> granicus.if.org Git - pdns/commitdiff
Merge branch 'usemmapforstack' of github.com:omoerbeek/pdns into usemmapforstack
authorOtto Moerbeek <otto.moerbeek@open-xchange.com>
Fri, 4 Jan 2019 13:17:57 +0000 (14:17 +0100)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Mon, 7 Jan 2019 08:14:10 +0000 (09:14 +0100)
1  2 
pdns/lazy_allocator.hh

index 629981c2cd8637e026132065d68b51c43bb990e7,629981c2cd8637e026132065d68b51c43bb990e7..4851687ba6f3c1079533b0325119f70e99b7c14c
@@@ -43,7 -43,7 +43,7 @@@ struct lazy_allocator 
  
      pointer
      allocate (size_type const n) {
--        void *p = mmap(NULL, n * sizeof(value_type),
++        void *p = mmap(nullptr, n * sizeof(value_type),
            PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON | MAP_STACK, -1, 0);
          if (p == MAP_FAILED)
            throw std::bad_alloc();