Closed
Bug 5082
Opened 26 years ago
Closed 22 years ago
[PP]PR_Open's PR_SYNC flag is not implemented on the Mac.
Categories
(NSPR :: NSPR, defect, P3)
Tracking
(Not tracked)
RESOLVED
WONTFIX
Future
People
(Reporter: wtc, Assigned: sdagley)
Details
(Whiteboard: potentially a wontfix, waiting on comments)
PR_Open's PR_SYNC flag is not implemented on the
Mac.
The PR_SYNC flag is modeled after the O_SYNC flag
of Unix's open() system call. If PR_SYNC is specified,
each write will wait for both the file data and file
status to be physically updated.
Assignee | ||
Updated•26 years ago
|
Assignee: gordon → sdagley
Assignee | ||
Comment 2•26 years ago
|
||
Offloading some of gordon's doomage
Comment 3•26 years ago
|
||
NSPR now has its own Bugzilla product. Moving this bug to the NSPR product.
Assignee | ||
Updated•26 years ago
|
Status: NEW → ASSIGNED
Assignee | ||
Updated•26 years ago
|
Target Milestone: M6 → M7
Assignee | ||
Comment 4•26 years ago
|
||
Deferring to M7 as this isn't a showstopper for M6.
Summary: PR_Open's PR_SYNC flag is not implemented on the Mac. → [PP]PR_Open's PR_SYNC flag is not implemented on the Mac.
Assignee | ||
Updated•26 years ago
|
Target Milestone: M7 → M8
Assignee | ||
Updated•26 years ago
|
Target Milestone: M8 → M9
Assignee | ||
Updated•26 years ago
|
Target Milestone: M9 → M10
Assignee | ||
Comment 5•25 years ago
|
||
We may want to close this bug as a WONTFIX. To actually force a write to media
we'd have to flush the volume after each which may not be desirable from the
performance standpoint. Gordon has pointed out to me that on the Mac it isn't
necessary to flush the file after each write if what you're trying for is inter-
process file synchronization.
Assignee | ||
Updated•25 years ago
|
Whiteboard: potentially a wontfix, waiting on comments
Assignee | ||
Comment 6•25 years ago
|
||
2nd line on previous comment should start:
we'd have to flush the volume after each write which may not be desirable
^^^^^
Assignee | ||
Updated•25 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → LATER
Assignee | ||
Comment 7•25 years ago
|
||
Per wtc's suggestion marking this LATER instead of WONTFIX so that when/if we've
got an OS on the Mac that supports/needs sync writes we can address the issue.
Comment 8•25 years ago
|
||
phillip gone, removing him from qa contact, sorry for spam
Comment 9•25 years ago
|
||
reopening all latered bugs
Status: RESOLVED → REOPENED
Resolution: LATER → ---
Comment 10•25 years ago
|
||
Moving all latered bugs to M20 as ordered by project manager. Although these
bugs are now open, assigned and targetted, XPToolkit has no plans to
fix/implement them in the current release cycle, if ever.
Target Milestone: M10 → M20
Comment 11•25 years ago
|
||
Mass move of all M20 bugs to M30.
Reporter | ||
Comment 12•25 years ago
|
||
Set target milestone "NSPR 4.1".
Steve, is it possible to implement the PR_SYNC
flag on Mac? PR_SYNC is modeled after the Unix
O_SYNC flag. It means that PR_Write() does not
return until the data has been written to the disk. See
http://www.opengroup.org/onlinepubs/007908799/xsh/open.html
(which doesn't explain O_SYNC clearly) or the
"open" man page on Unix.
Target Milestone: M20 → 4.1
Comment 13•25 years ago
|
||
I think all we would have to do is flush the volume afert writing. This slows
down the call, but it guarantees the data to be written to disk. Even closing a
file however, doesn't guarantee that information is written to disk, until
PBFlushVol is called.
Comment 14•25 years ago
|
||
Also, PBFlushFile will make sure the data is written to disk, but it doesn't
necessarily write the catalog and extents entries to disk. This means if a write
to a file extends the file, and a crash occurs before FlushVol is called, even if
PBFlushFile has been called, the file will appear to have it's old EOF and
extents, but whatever new data was written before the crash.
Reporter | ||
Comment 15•25 years ago
|
||
Would PBFlushFile be cheaper than PBFlushVol,
or do we really need to call PBFlushVol?
The Mac implementation of PR_Sync calls
PBFlushFile. (Note that PR_Sync is a function
while PR_SYNC is a flag for the PR_Open function.)
Is it possible to open a file so that flush is
automatically done by the OS? Otherwise, we'll
have to emulate it by calling PBFlushVol or
PBFlushFile after every write. This emulation
would suffer from the non-atomicity problem that
you just described.
Reporter | ||
Comment 16•24 years ago
|
||
Can't fix this in time for NSPR 4.1.
Target Milestone: 4.1 → Future
Assignee | ||
Comment 17•22 years ago
|
||
Revisiting old open bugs... With the impending dropping of support for Mac OS
versions prior to Mac OS X and the move to a mach-o based build when Mac NSPR is
basically BSD *nix NSPR can this bug be retired?
Assignee | ||
Comment 18•22 years ago
|
||
Per Wan-Teh's agreement closing WONTFIX
Status: REOPENED → RESOLVED
Closed: 25 years ago → 22 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•