Skip to content
This repository has been archived by the owner on Aug 20, 2022. It is now read-only.

Commit

Permalink
Reduce Windows page size to 4KB
Browse files Browse the repository at this point in the history
As of right now, there is no reliable way to determine the Windows
default page size without including additional modules.  For for
the safest assumption of 4KB.  Linux, until 2.6.38 with transparent
huge pages, uses 4KB by default as well.
  • Loading branch information
Kevin Landreth committed May 1, 2012
1 parent 0263cbc commit b45260d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions slbackup.py
Expand Up @@ -38,8 +38,9 @@
try:
import resource
except ImportError:
# well, must be windows, assume an 8MB slab
_DEFAULT_OS_BUFLEN=8*1024*1024
# well, must be windows, assume an 4Kb slab
# regardless if long mode is supported
_DEFAULT_OS_BUFLEN=4*1024
else:
_DEFAULT_OS_BUFLEN=resource.getpagesize()

Expand Down

0 comments on commit b45260d

Please sign in to comment.