Observed on WSL. Thanks to Levent Dane <leventdane@gmail.com> for
reporting the problem and helping test the fix.
Signed-off-by: Rob Browning <rlb@defaultvalue.org>
of corruption.
- It currently only works on Linux, FreeBSD, NetBSD, OS X >= 10.4,
- Solaris, or Windows (with Cygwin). Patches to support other
- platforms are welcome.
+ Solaris, or Windows (with Cygwin, and maybe with WSL). Patches to
+ support other platforms are welcome.
- Any items in "Things that are stupid" below.
# Perhaps the file was a pipe, i.e. "... | bup split ..."
return None
raise ex
- _mincore(m, msize, 0, result, ci * pages_per_chunk);
+ try:
+ _mincore(m, msize, 0, result, ci * pages_per_chunk)
+ except OSError as ex:
+ if ex.errno == errno.ENOSYS:
+ return None
+ raise
return result