[Xapian-tickets] [Xapian] #651: Avoid low fds
Xapian
nobody at xapian.org
Thu Dec 4 12:57:06 GMT 2014
#651: Avoid low fds
---------------------------+--------------------------
Reporter: olly | Owner: olly
Type: enhancement | Status: new
Priority: normal | Milestone: 1.3.3
Component: Backend-Glass | Version:
Severity: normal | Resolution:
Keywords: | Blocked By:
Blocking: | Operating System: All
---------------------------+--------------------------
Comment (by olly):
It occurs to me that a simple general measure to make database tables much
safer from writes to their fd (e.g. by user code or another library that
previously had that fd open) would be to {{{lseek()}}} to way beyond the
end of the file right after opening it for writing. Doing so is
documented to not change the file size (unless data is actually written),
and calls to {{{pread()}}} and {{{pwrite()}}} are documented to not change
the file offset.
--
Ticket URL: <http://trac.xapian.org/ticket/651#comment:2>
Xapian <http://xapian.org/>
Xapian
More information about the Xapian-tickets
mailing list