zbackup/page_size.cc

17 lines
357 B
C++
Raw Permalink Normal View History

2014-12-11 10:50:15 +03:00
// Copyright (c) 2012-2014 Konstantin Isakov <ikm@zbackup.org> and ZBackup contributors, see CONTRIBUTORS
// Part of ZBackup. Licensed under GNU GPLv2 or later + OpenSSL, see LICENSE
2013-07-18 21:33:25 +04:00
#include "page_size.hh"
#include <unistd.h>
unsigned getPageSize()
{
static unsigned value = 0;
if ( !value )
value = sysconf( _SC_PAGESIZE );
return value;
}