|
|
DataMuseum.dkPresents historical artifacts from the history of: RC9000 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about RC9000 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - downloadIndex: f
Length: 8206 (0x200e)
Names: »flock.2«
└─⟦50656ff4a⟧ Bits:30010538 TX 3.1 Coldstart
└─⟦bbf173f5c⟧ »0004«
└─⟦this⟧ »./bsd/usr/man/cat2/flock.2«
0x0000…0020 0a 0a 0a 5f 08 4f 5f 08 6e 5f 08 6c 5f 08 69 5f 08 6e 5f 08 65 20 5f 08 4d 5f 08 61 5f 08 6e 5f ┆ _ O_ n_ l_ i_ n_ e _ M_ a_ n_┆ 0x0020…0040 08 75 5f 08 61 5f 08 6c 20 20 20 20 20 20 20 20 20 20 20 20 20 53 79 73 74 65 6d 20 43 61 6c 6c ┆ u_ a_ l System Call┆ 0x0040…0060 73 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6c 6f 63 6b 28 32 29 0a 0a 0a 0a ┆s flock(2) ┆ 0x0060…0080 4e 08 4e 08 4e 08 4e 41 08 41 08 41 08 41 4d 08 4d 08 4d 08 4d 45 08 45 08 45 08 45 0a 20 20 20 ┆N N N NA A A AM M M ME E E E ┆ 0x0080…00a0 20 20 66 6c 6f 63 6b 20 2d 20 61 70 70 6c 79 2c 20 63 68 61 6e 67 65 2c 20 6f 72 20 72 65 6d 6f ┆ flock - apply, change, or remo┆ 0x00a0…00c0 76 65 20 61 20 66 69 6c 65 2d 6c 65 76 65 6c 20 6c 6f 63 6b 20 6f 6e 20 61 6e 0a 20 20 20 20 20 ┆ve a file-level lock on an ┆ 0x00c0…00e0 6f 70 65 6e 20 66 69 6c 65 0a 0a 53 08 53 08 53 08 53 59 08 59 08 59 08 59 4e 08 4e 08 4e 08 4e ┆open file S S S SY Y Y YN N N N┆ 0x00e0…0100 54 08 54 08 54 08 54 41 08 41 08 41 08 41 58 08 58 08 58 08 58 0a 20 20 20 20 20 23 08 23 08 23 ┆T T T TA A A AX X X X # # #┆ 0x0100…0120 08 23 69 08 69 08 69 08 69 6e 08 6e 08 6e 08 6e 63 08 63 08 63 08 63 6c 08 6c 08 6c 08 6c 75 08 ┆ #i i i in n n nc c c cl l l lu ┆ 0x0120…0140 75 08 75 08 75 64 08 64 08 64 08 64 65 08 65 08 65 08 65 20 3c 08 3c 08 3c 08 3c 73 08 73 08 73 ┆u u ud d d de e e e < < < <s s s┆ 0x0140…0160 08 73 79 08 79 08 79 08 79 73 08 73 08 73 08 73 2f 08 2f 08 2f 08 2f 66 08 66 08 66 08 66 69 08 ┆ sy y y ys s s s/ / / /f f f fi ┆ 0x0160…0180 69 08 69 08 69 6c 08 6c 08 6c 08 6c 65 08 65 08 65 08 65 2e 08 2e 08 2e 08 2e 68 08 68 08 68 08 ┆i i il l l le e e e. . . .h h h ┆ 0x0180…01a0 68 3e 08 3e 08 3e 08 3e 0a 0a 20 20 20 20 20 23 08 23 08 23 08 23 64 08 64 08 64 08 64 65 08 65 ┆h> > > > # # # #d d d de e┆ 0x01a0…01c0 08 65 08 65 66 08 66 08 66 08 66 69 08 69 08 69 08 69 6e 08 6e 08 6e 08 6e 65 08 65 08 65 08 65 ┆ e ef f f fi i i in n n ne e e e┆ 0x01c0…01e0 20 20 20 4c 08 4c 08 4c 08 4c 4f 08 4f 08 4f 08 4f 43 08 43 08 43 08 43 4b 08 4b 08 4b 08 4b 5f ┆ L L L LO O O OC C C CK K K K_┆ 0x01e0…0200 08 5f 08 5f 08 5f 53 08 53 08 53 08 53 48 08 48 08 48 08 48 20 20 20 31 08 31 08 31 08 31 20 20 ┆ _ _ _S S S SH H H H 1 1 1 1 ┆ 0x0200…0220 20 20 2f 08 2f 08 2f 08 2f 2a 08 2a 08 2a 08 2a 20 73 08 73 08 73 08 73 68 08 68 08 68 08 68 61 ┆ / / / /* * * * s s s sh h h ha┆ 0x0220…0240 08 61 08 61 08 61 72 08 72 08 72 08 72 65 08 65 08 65 08 65 64 08 64 08 64 08 64 20 6c 08 6c 08 ┆ a a ar r r re e e ed d d d l l ┆ 0x0240…0260 6c 08 6c 6f 08 6f 08 6f 08 6f 63 08 63 08 63 08 63 6b 08 6b 08 6b 08 6b 20 2a 08 2a 08 2a 08 2a ┆l lo o o oc c c ck k k k * * * *┆ 0x0260…0280 2f 08 2f 08 2f 08 2f 0a 20 20 20 20 20 23 08 23 08 23 08 23 64 08 64 08 64 08 64 65 08 65 08 65 ┆/ / / / # # # #d d d de e e┆ 0x0280…02a0 08 65 66 08 66 08 66 08 66 69 08 69 08 69 08 69 6e 08 6e 08 6e 08 6e 65 08 65 08 65 08 65 20 20 ┆ ef f f fi i i in n n ne e e e ┆ 0x02a0…02c0 20 4c 08 4c 08 4c 08 4c 4f 08 4f 08 4f 08 4f 43 08 43 08 43 08 43 4b 08 4b 08 4b 08 4b 5f 08 5f ┆ L L L LO O O OC C C CK K K K_ _┆ 0x02c0…02e0 08 5f 08 5f 45 08 45 08 45 08 45 58 08 58 08 58 08 58 20 20 20 32 08 32 08 32 08 32 20 20 20 20 ┆ _ _E E E EX X X X 2 2 2 2 ┆ 0x02e0…0300 2f 08 2f 08 2f 08 2f 2a 08 2a 08 2a 08 2a 20 65 08 65 08 65 08 65 78 08 78 08 78 08 78 63 08 63 ┆/ / / /* * * * e e e ex x x xc c┆ 0x0300…0320 08 63 08 63 6c 08 6c 08 6c 08 6c 75 08 75 08 75 08 75 73 08 73 08 73 08 73 69 08 69 08 69 08 69 ┆ c cl l l lu u u us s s si i i i┆ 0x0320…0340 76 08 76 08 76 08 76 65 08 65 08 65 08 65 20 6c 08 6c 08 6c 08 6c 6f 08 6f 08 6f 08 6f 63 08 63 ┆v v v ve e e e l l l lo o o oc c┆ 0x0340…0360 08 63 08 63 6b 08 6b 08 6b 08 6b 20 2a 08 2a 08 2a 08 2a 2f 08 2f 08 2f 08 2f 0a 20 20 20 20 20 ┆ c ck k k k * * * */ / / / ┆ 0x0360…0380 23 08 23 08 23 08 23 64 08 64 08 64 08 64 65 08 65 08 65 08 65 66 08 66 08 66 08 66 69 08 69 08 ┆# # # #d d d de e e ef f f fi i ┆ 0x0380…03a0 69 08 69 6e 08 6e 08 6e 08 6e 65 08 65 08 65 08 65 20 20 20 4c 08 4c 08 4c 08 4c 4f 08 4f 08 4f ┆i in n n ne e e e L L L LO O O┆ 0x03a0…03c0 08 4f 43 08 43 08 43 08 43 4b 08 4b 08 4b 08 4b 5f 08 5f 08 5f 08 5f 4e 08 4e 08 4e 08 4e 42 08 ┆ OC C C CK K K K_ _ _ _N N N NB ┆ 0x03c0…03e0 42 08 42 08 42 20 20 20 34 08 34 08 34 08 34 20 20 20 20 2f 08 2f 08 2f 08 2f 2a 08 2a 08 2a 08 ┆B B B 4 4 4 4 / / / /* * * ┆ 0x03e0…0400 2a 20 64 08 64 08 64 08 64 6f 08 6f 08 6f 08 6f 6e 08 6e 08 6e 08 6e 27 08 27 08 27 08 27 74 08 ┆* d d d do o o on n n n' ' ' 't ┆ 0x0400…0420 74 08 74 08 74 20 62 08 62 08 62 08 62 6c 08 6c 08 6c 08 6c 6f 08 6f 08 6f 08 6f 63 08 63 08 63 ┆t t t b b b bl l l lo o o oc c c┆ 0x0420…0440 08 63 6b 08 6b 08 6b 08 6b 20 77 08 77 08 77 08 77 68 08 68 08 68 08 68 65 08 65 08 65 08 65 6e ┆ ck k k k w w w wh h h he e e en┆ 0x0440…0460 08 6e 08 6e 08 6e 20 6c 08 6c 08 6c 08 6c 6f 08 6f 08 6f 08 6f 63 08 63 08 63 08 63 6b 08 6b 08 ┆ n n n l l l lo o o oc c c ck k ┆ 0x0460…0480 6b 08 6b 69 08 69 08 69 08 69 6e 08 6e 08 6e 08 6e 67 08 67 08 67 08 67 20 2a 08 2a 08 2a 08 2a ┆k ki i i in n n ng g g g * * * *┆ 0x0480…04a0 2f 08 2f 08 2f 08 2f 0a 20 20 20 20 20 23 08 23 08 23 08 23 64 08 64 08 64 08 64 65 08 65 08 65 ┆/ / / / # # # #d d d de e e┆ 0x04a0…04c0 08 65 66 08 66 08 66 08 66 69 08 69 08 69 08 69 6e 08 6e 08 6e 08 6e 65 08 65 08 65 08 65 20 20 ┆ ef f f fi i i in n n ne e e e ┆ 0x04c0…04e0 20 4c 08 4c 08 4c 08 4c 4f 08 4f 08 4f 08 4f 43 08 43 08 43 08 43 4b 08 4b 08 4b 08 4b 5f 08 5f ┆ L L L LO O O OC C C CK K K K_ _┆ 0x04e0…0500 08 5f 08 5f 55 08 55 08 55 08 55 4e 08 4e 08 4e 08 4e 20 20 20 38 08 38 08 38 08 38 20 20 20 20 ┆ _ _U U U UN N N N 8 8 8 8 ┆ 0x0500…0520 2f 08 2f 08 2f 08 2f 2a 08 2a 08 2a 08 2a 20 75 08 75 08 75 08 75 6e 08 6e 08 6e 08 6e 6c 08 6c ┆/ / / /* * * * u u u un n n nl l┆ 0x0520…0540 08 6c 08 6c 6f 08 6f 08 6f 08 6f 63 08 63 08 63 08 63 6b 08 6b 08 6b 08 6b 20 2a 08 2a 08 2a 08 ┆ l lo o o oc c c ck k k k * * * ┆ 0x0540…0560 2a 2f 08 2f 08 2f 08 2f 0a 0a 20 20 20 20 20 66 08 66 08 66 08 66 6c 08 6c 08 6c 08 6c 6f 08 6f ┆*/ / / / f f f fl l l lo o┆ 0x0560…0580 08 6f 08 6f 63 08 63 08 63 08 63 6b 08 6b 08 6b 08 6b 28 08 28 08 28 08 28 66 08 66 08 66 08 66 ┆ o oc c c ck k k k( ( ( (f f f f┆ 0x0580…05a0 64 08 64 08 64 08 64 2c 08 2c 08 2c 08 2c 20 6f 08 6f 08 6f 08 6f 70 08 70 08 70 08 70 65 08 65 ┆d d d d, , , , o o o op p p pe e┆ 0x05a0…05c0 08 65 08 65 72 08 72 08 72 08 72 61 08 61 08 61 08 61 74 08 74 08 74 08 74 69 08 69 08 69 08 69 ┆ e er r r ra a a at t t ti i i i┆ 0x05c0…05e0 6f 08 6f 08 6f 08 6f 6e 08 6e 08 6e 08 6e 29 08 29 08 29 08 29 0a 20 20 20 20 20 69 08 69 08 69 ┆o o o on n n n) ) ) ) i i i┆ 0x05e0…0600 08 69 6e 08 6e 08 6e 08 6e 74 08 74 08 74 08 74 20 66 08 66 08 66 08 66 64 08 64 08 64 08 64 2c ┆ in n n nt t t t f f f fd d d d,┆ 0x0600…0620 08 2c 08 2c 08 2c 20 6f 08 6f 08 6f 08 6f 70 08 70 08 70 08 70 65 08 65 08 65 08 65 72 08 72 08 ┆ , , , o o o op p p pe e e er r ┆ 0x0620…0640 72 08 72 61 08 61 08 61 08 61 74 08 74 08 74 08 74 69 08 69 08 69 08 69 6f 08 6f 08 6f 08 6f 6e ┆r ra a a at t t ti i i io o o on┆ 0x0640…0660 08 6e 08 6e 08 6e 3b 08 3b 08 3b 08 3b 0a 0a 44 08 44 08 44 08 44 45 08 45 08 45 08 45 53 08 53 ┆ n n n; ; ; ; D D D DE E E ES S┆ 0x0660…0680 08 53 08 53 43 08 43 08 43 08 43 52 08 52 08 52 08 52 49 08 49 08 49 08 49 50 08 50 08 50 08 50 ┆ S SC C C CR R R RI I I IP P P P┆ 0x0680…06a0 54 08 54 08 54 08 54 49 08 49 08 49 08 49 4f 08 4f 08 4f 08 4f 4e 08 4e 08 4e 08 4e 0a 20 20 20 ┆T T T TI I I IO O O ON N N N ┆ 0x06a0…06c0 20 20 5f 08 66 5f 08 6c 5f 08 6f 5f 08 63 5f 08 6b 20 61 6c 6c 6f 77 73 20 61 20 70 72 6f 63 65 ┆ _ f_ l_ o_ c_ k allows a proce┆ 0x06c0…06e0 73 73 20 74 6f 20 6d 61 6e 61 67 65 20 66 69 6c 65 2d 6c 65 76 65 6c 20 6c 6f 63 6b 73 2e 0a 0a ┆ss to manage file-level locks. ┆ 0x06e0…0700 20 20 20 20 20 66 08 66 08 66 08 66 64 08 64 08 64 08 64 20 20 20 53 70 65 63 69 66 69 65 73 20 ┆ f f f fd d d d Specifies ┆ 0x0700…0720 74 68 65 20 66 69 6c 65 20 64 65 73 63 72 69 70 74 6f 72 20 6f 66 20 74 68 65 20 66 69 6c 65 20 ┆the file descriptor of the file ┆ 0x0720…0740 77 68 6f 73 65 20 6c 6f 63 6b 20 69 73 0a 20 20 20 20 20 20 20 20 20 20 62 65 69 6e 67 20 6d 6f ┆whose lock is being mo┆ 0x0740…0760 64 69 66 69 65 64 2e 0a 0a 20 20 20 20 20 6f 08 6f 08 6f 08 6f 70 08 70 08 70 08 70 65 08 65 08 ┆dified. o o o op p p pe e ┆ 0x0760…0780 65 08 65 72 08 72 08 72 08 72 61 08 61 08 61 08 61 74 08 74 08 74 08 74 69 08 69 08 69 08 69 6f ┆e er r r ra a a at t t ti i i io┆ 0x0780…07a0 08 6f 08 6f 08 6f 6e 08 6e 08 6e 08 6e 0a 20 20 20 20 20 20 20 20 20 20 53 70 65 63 69 66 69 65 ┆ o o on n n n Specifie┆ 0x07a0…07c0 73 20 74 68 65 20 74 79 70 65 20 6f 66 20 6c 6f 63 6b 20 62 65 69 6e 67 20 6d 61 6e 61 67 65 64 ┆s the type of lock being managed┆ 0x07c0…07e0 2c 20 77 68 65 74 68 65 72 20 69 74 20 69 73 0a 20 20 20 20 20 20 20 20 20 20 62 65 69 6e 67 20 ┆, whether it is being ┆ 0x07e0…0800 72 65 6d 6f 76 65 64 20 6f 72 20 61 64 64 65 64 20 61 6e 64 20 77 68 65 74 68 65 72 20 74 68 65 ┆removed or added and whether the┆ 0x0800…0820 20 63 61 6c 6c 20 6d 61 79 20 62 6c 6f 63 6b 0a 20 20 20 20 20 20 20 20 20 20 77 61 69 74 69 6e ┆ call may block waitin┆ 0x0820…0840 67 20 66 6f 72 20 74 68 65 20 6c 6f 63 6b 2e 20 20 54 68 65 20 63 6f 6d 70 6c 65 74 65 20 6f 70 ┆g for the lock. The complete op┆ 0x0840…0860 65 72 61 74 69 6f 6e 20 69 73 20 73 70 65 63 69 2d 0a 20 20 20 20 20 20 20 20 20 20 66 69 65 64 ┆eration is speci- fied┆ 0x0860…0880 20 62 79 20 5f 08 6f 5f 08 72 69 6e 67 20 28 20 7c 20 29 20 74 68 65 20 76 61 72 69 6f 75 73 20 ┆ by _ o_ ring ( | ) the various ┆ 0x0880…08a0 64 65 66 69 6e 65 73 20 74 6f 67 65 74 68 65 72 2e 0a 0a 20 20 20 20 20 20 20 20 20 20 4c 4f 43 ┆defines together. LOC┆ 0x08a0…08c0 4b 5f 53 48 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 64 69 63 61 74 65 73 20 74 68 ┆K_SH indicates th┆ 0x08c0…08e0 61 74 20 61 20 73 68 61 72 65 64 20 6c 6f 63 6b 20 69 73 20 62 65 69 6e 67 20 6d 61 6e 61 67 65 ┆at a shared lock is being manage┆ 0x08e0…0900 64 2e 0a 0a 20 20 20 20 20 20 20 20 20 20 4c 4f 43 4b 5f 45 58 0a 20 20 20 20 20 20 20 20 20 20 ┆d. LOCK_EX ┆ 0x0900…0920 20 20 20 20 20 69 6e 64 69 63 61 74 65 73 20 74 68 61 74 20 61 6e 20 65 78 63 6c 75 73 69 76 65 ┆ indicates that an exclusive┆ 0x0920…0940 20 6c 6f 63 6b 20 69 73 20 62 65 69 6e 67 20 6d 61 6e 61 67 65 64 2e 0a 0a 20 20 20 20 20 20 20 ┆ lock is being managed. ┆ 0x0940…0960 20 20 20 4c 4f 43 4b 5f 4e 42 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 64 69 63 61 ┆ LOCK_NB indica┆ 0x0960…0980 74 65 73 20 74 68 61 74 20 74 68 65 20 63 61 6c 6c 20 6d 75 73 74 20 6e 6f 74 20 62 6c 6f 63 6b ┆tes that the call must not block┆ 0x0980…09a0 20 77 68 69 6c 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 74 74 65 6d 70 74 69 6e 67 ┆ while attempting┆ 0x09a0…09c0 20 74 6f 20 61 63 71 75 69 72 65 20 61 20 6c 6f 63 6b 2e 0a 0a 20 20 20 20 20 20 20 20 20 20 4c ┆ to acquire a lock. L┆ 0x09c0…09e0 4f 43 4b 5f 55 4e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 64 69 63 61 74 65 73 20 ┆OCK_UN indicates ┆ 0x09e0…0a00 74 68 61 74 20 74 68 65 20 73 70 65 63 69 66 69 65 64 20 6c 6f 63 6b 20 69 73 20 62 65 69 6e 67 ┆that the specified lock is being┆ 0x0a00…0a20 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 6d 6f 76 65 64 2e 0a 0a 20 20 20 20 20 53 ┆ removed. S┆ 0x0a20…0a40 08 53 08 53 08 53 79 08 79 08 79 08 79 73 08 73 08 73 08 73 74 08 74 08 74 08 74 65 08 65 08 65 ┆ S S Sy y y ys s s st t t te e e┆ 0x0a40…0a60 08 65 6d 08 6d 08 6d 08 6d 20 4c 08 4c 08 4c 08 4c 6f 08 6f 08 6f 08 6f 63 08 63 08 63 08 63 6b ┆ em m m m L L L Lo o o oc c c ck┆ 0x0a60…0a80 08 6b 08 6b 08 6b 20 52 08 52 08 52 08 52 65 08 65 08 65 08 65 71 08 71 08 71 08 71 75 08 75 08 ┆ k k k R R R Re e e eq q q qu u ┆ 0x0a80…0aa0 75 08 75 69 08 69 08 69 08 69 72 08 72 08 72 08 72 65 08 65 08 65 08 65 6d 08 6d 08 6d 08 6d 65 ┆u ui i i ir r r re e e em m m me┆ 0x0aa0…0ac0 08 65 08 65 08 65 6e 08 6e 08 6e 08 6e 74 08 74 08 74 08 74 73 08 73 08 73 08 73 0a 20 20 20 20 ┆ e e en n n nt t t ts s s s ┆ 0x0ac0…0ae0 20 54 58 20 66 6f 72 63 65 73 20 61 6c 6c 20 70 72 6f 67 72 61 6d 73 20 74 6f 20 6f 62 73 65 72 ┆ TX forces all programs to obser┆ 0x0ae0…0b00 76 65 20 74 68 65 20 6c 6f 63 6b 69 6e 67 20 63 6f 6e 73 74 72 61 69 6e 74 73 2e 0a 20 20 20 20 ┆ve the locking constraints. ┆ 0x0b00…0b20 20 54 68 65 72 65 20 61 72 65 20 34 20 74 79 70 65 73 20 6f 66 20 66 69 6c 65 20 6c 6f 63 6b 73 ┆ There are 4 types of file locks┆ 0x0b20…0b40 20 61 76 61 69 6c 61 62 6c 65 3a 0a 0a 20 20 20 20 20 49 53 20 20 20 6f 62 74 61 69 6e 65 64 20 ┆ available: IS obtained ┆ 0x0b40…0b60 77 68 65 6e 20 74 68 65 20 66 69 6c 65 20 69 73 20 6f 70 65 6e 65 64 20 77 69 74 68 20 72 65 61 ┆when the file is opened with rea┆ 0x0b60…0b80 64 2d 6f 6e 6c 79 20 61 63 63 65 73 73 2e 0a 20 20 20 20 20 20 20 20 20 20 41 6e 20 49 53 20 6c ┆d-only access. An IS l┆ 0x0b80…0ba0 6f 63 6b 20 69 73 20 63 6f 6d 70 61 74 69 62 6c 65 20 77 69 74 68 20 6f 74 68 65 72 20 49 53 20 ┆ock is compatible with other IS ┆ 0x0ba0…0bc0 6c 6f 63 6b 73 2c 20 77 69 74 68 20 49 58 0a 20 20 20 20 20 20 20 20 20 20 6c 6f 63 6b 73 2c 20 ┆locks, with IX locks, ┆ 0x0bc0…0be0 61 6e 64 20 77 69 74 68 20 53 20 6c 6f 63 6b 73 2e 0a 0a 20 20 20 20 20 49 58 20 20 20 6f 62 74 ┆and with S locks. IX obt┆ 0x0be0…0c00 61 69 6e 65 64 20 77 68 65 6e 20 74 68 65 20 66 69 6c 65 73 20 69 73 20 6f 70 65 6e 65 64 20 77 ┆ained when the files is opened w┆ 0x0c00…0c20 69 74 68 20 72 65 61 64 2f 77 72 69 74 65 2c 0a 20 20 20 20 20 20 20 20 20 20 77 72 69 74 65 2d ┆ith read/write, write-┆ 0x0c20…0c40 6f 6e 6c 79 2c 20 6f 72 20 61 70 70 65 6e 64 20 61 63 63 65 73 73 2e 20 20 41 6e 20 49 58 20 6c ┆only, or append access. An IX l┆ 0x0c40…0c60 6f 63 6b 20 69 73 20 63 6f 6d 70 61 74 69 62 6c 65 0a 20 20 20 20 20 20 20 20 20 20 77 69 74 68 ┆ock is compatible with┆ 0x0c60…0c80 20 6f 74 68 65 72 20 49 58 20 6c 6f 63 6b 73 20 61 6e 64 20 77 69 74 68 20 49 53 20 6c 6f 63 6b ┆ other IX locks and with IS lock┆ 0x0c80…0ca0 73 2e 0a 0a 20 20 20 20 20 53 20 20 20 20 6f 62 74 61 69 6e 65 64 20 77 68 65 6e 20 74 68 65 20 ┆s. S obtained when the ┆ 0x0ca0…0cc0 66 69 6c 65 20 69 73 20 6f 70 65 6e 65 64 20 77 69 74 68 20 74 68 65 20 4f 5f 53 48 4c 4f 43 4b ┆file is opened with the O_SHLOCK┆ 0x0cc0…0ce0 20 66 6c 61 67 0a 20 20 20 20 20 20 20 20 20 20 6f 72 20 77 68 65 6e 20 74 68 65 20 5f 08 66 5f ┆ flag or when the _ f_┆ 0x0ce0…0d00 08 6c 5f 08 6f 5f 08 63 5f 08 6b 20 63 61 6c 6c 20 69 73 20 6d 61 64 65 2e 20 20 41 6e 20 53 20 ┆ l_ o_ c_ k call is made. An S ┆ 0x0d00…0d20 6c 6f 63 6b 20 69 73 20 63 6f 6d 70 61 74 69 2d 0a 20 20 20 20 20 20 20 20 20 20 62 6c 65 20 77 ┆lock is compati- ble w┆ 0x0d20…0d40 69 74 68 20 6f 74 68 65 72 20 53 20 6c 6f 63 6b 73 20 61 6e 64 20 77 69 74 68 20 49 53 20 6c 6f ┆ith other S locks and with IS lo┆ 0x0d40…0d60 63 6b 73 2e 0a 0a 20 20 20 20 20 58 20 20 20 20 6f 62 74 61 69 6e 65 64 20 77 68 65 6e 20 74 68 ┆cks. X obtained when th┆ 0x0d60…0d80 65 20 66 69 6c 65 20 69 73 20 6f 70 65 6e 65 64 20 77 69 74 68 20 74 68 65 20 4f 5f 45 58 4c 4f ┆e file is opened with the O_EXLO┆ 0x0d80…0da0 43 4b 20 66 6c 61 67 0a 20 20 20 20 20 20 20 20 20 20 6f 72 20 77 68 65 6e 20 74 68 65 20 5f 08 ┆CK flag or when the _ ┆ 0x0da0…0dc0 66 5f 08 6c 5f 08 6f 5f 08 63 5f 08 6b 20 63 61 6c 6c 20 69 73 20 6d 61 64 65 2e 20 20 41 6e 20 ┆f_ l_ o_ c_ k call is made. An ┆ 0x0dc0…0de0 58 20 6c 6f 63 6b 20 69 73 20 6e 6f 74 0a 0a 0a 0a 0a 0a 0a 20 20 20 20 20 20 20 20 20 20 63 6f ┆X lock is not co┆ 0x0de0…0e00 6d 70 61 74 69 62 6c 65 20 77 69 74 68 20 61 6e 79 20 6f 74 68 65 72 20 6c 6f 63 6b 73 2e 0a 0a ┆mpatible with any other locks. ┆ 0x0e00…0e20 20 20 20 20 20 43 08 43 08 43 08 43 75 08 75 08 75 08 75 72 08 72 08 72 08 72 72 08 72 08 72 08 ┆ C C C Cu u u ur r r rr r r ┆ 0x0e20…0e40 72 65 08 65 08 65 08 65 6e 08 6e 08 6e 08 6e 74 08 74 08 74 08 74 2d 08 2d 08 2d 08 2d 4c 08 4c ┆re e e en n n nt t t t- - - -L L┆ 0x0e40…0e60 08 4c 08 4c 6f 08 6f 08 6f 08 6f 63 08 63 08 63 08 63 6b 08 6b 08 6b 08 6b 20 53 08 53 08 53 08 ┆ L Lo o o oc c c ck k k k S S S ┆ 0x0e60…0e80 53 74 08 74 08 74 08 74 61 08 61 08 61 08 61 74 08 74 08 74 08 74 65 08 65 08 65 08 65 2e 08 2e ┆St t t ta a a at t t te e e e. .┆ 0x0e80…0ea0 08 2e 08 2e 20 20 54 68 65 20 73 79 73 74 65 6d 20 6d 61 69 6e 74 61 69 6e 73 20 74 68 65 20 63 ┆ . . The system maintains the c┆ 0x0ea0…0ec0 75 72 72 65 6e 74 2d 6c 6f 63 6b 0a 20 20 20 20 20 73 74 61 74 65 20 66 6f 72 20 65 61 63 68 20 ┆urrent-lock state for each ┆ 0x0ec0…0ee0 66 69 6c 65 2e 20 20 54 68 69 73 20 69 73 20 74 68 65 20 6d 6f 73 74 20 72 65 73 74 72 69 63 74 ┆file. This is the most restrict┆ 0x0ee0…0f00 69 76 65 20 6c 6f 63 6b 20 69 6e 0a 20 20 20 20 20 65 66 66 65 63 74 20 6f 6e 20 74 68 65 20 66 ┆ive lock in effect on the f┆ 0x0f00…0f20 69 6c 65 2e 20 20 41 64 64 69 74 69 6f 6e 61 6c 20 6c 6f 63 6b 20 72 65 71 75 65 73 74 73 20 61 ┆ile. Additional lock requests a┆ 0x0f20…0f40 72 65 20 63 6f 6d 70 61 72 65 64 0a 20 20 20 20 20 61 67 61 69 6e 73 74 20 74 68 65 20 63 75 72 ┆re compared against the cur┆ 0x0f40…0f60 72 65 6e 74 20 73 74 61 74 65 20 74 6f 20 64 65 74 65 72 6d 69 6e 65 20 63 6f 6d 70 61 74 69 62 ┆rent state to determine compatib┆ 0x0f60…0f80 69 6c 69 74 79 2e 0a 0a 20 20 20 20 20 54 08 54 08 54 08 54 72 08 72 08 72 08 72 61 08 61 08 61 ┆ility. T T T Tr r r ra a a┆ 0x0f80…0fa0 08 61 6e 08 6e 08 6e 08 6e 73 08 73 08 73 08 73 61 08 61 08 61 08 61 63 08 63 08 63 08 63 74 08 ┆ an n n ns s s sa a a ac c c ct ┆ 0x0fa0…0fc0 74 08 74 08 74 69 08 69 08 69 08 69 6f 08 6f 08 6f 08 6f 6e 08 6e 08 6e 08 6e 73 08 73 08 73 08 ┆t t ti i i io o o on n n ns s s ┆ 0x0fc0…0fe0 73 2e 08 2e 08 2e 08 2e 20 20 54 58 20 70 65 72 66 6f 72 6d 73 20 61 75 74 6f 6d 61 74 69 63 20 ┆s. . . . TX performs automatic ┆ 0x0fe0…1000 6c 6f 63 6b 69 6e 67 20 28 61 74 20 74 68 65 20 64 61 74 61 2d 0a 20 20 20 20 20 62 6c 6f 63 6b ┆locking (at the data- block┆ 0x1000…1020 20 6c 65 76 65 6c 29 20 66 6f 72 20 66 69 6c 65 73 20 74 68 61 74 20 61 72 65 20 6f 70 65 6e 65 ┆ level) for files that are opene┆ 0x1020…1040 64 20 77 69 74 68 20 74 68 65 20 4f 5f 43 4f 4e 54 52 4f 4c 0a 20 20 20 20 20 66 6c 61 67 20 73 ┆d with the O_CONTROL flag s┆ 0x1040…1060 65 74 20 61 6e 64 20 61 72 65 20 75 73 65 64 20 69 6e 20 74 72 61 6e 73 61 63 74 69 6f 6e 20 6d ┆et and are used in transaction m┆ 0x1060…1080 6f 64 65 2e 0a 0a 20 20 20 20 20 4d 08 4d 08 4d 08 4d 75 08 75 08 75 08 75 6c 08 6c 08 6c 08 6c ┆ode. M M M Mu u u ul l l l┆ 0x1080…10a0 74 08 74 08 74 08 74 69 08 69 08 69 08 69 70 08 70 08 70 08 70 6c 08 6c 08 6c 08 6c 65 08 65 08 ┆t t t ti i i ip p p pl l l le e ┆ 0x10a0…10c0 65 08 65 20 4c 08 4c 08 4c 08 4c 6f 08 6f 08 6f 08 6f 63 08 63 08 63 08 63 6b 08 6b 08 6b 08 6b ┆e e L L L Lo o o oc c c ck k k k┆ 0x10c0…10e0 73 08 73 08 73 08 73 2e 08 2e 08 2e 08 2e 20 20 4d 75 6c 74 69 70 6c 65 20 6c 6f 63 6b 73 20 6d ┆s s s s. . . . Multiple locks m┆ 0x10e0…1100 61 79 20 62 65 20 61 70 70 6c 69 65 64 20 74 6f 20 61 20 66 69 6c 65 20 62 79 0a 20 20 20 20 20 ┆ay be applied to a file by ┆ 0x1100…1120 74 68 65 20 73 61 6d 65 20 70 72 6f 63 65 73 73 2e 20 20 54 68 65 20 60 60 65 66 66 65 63 74 69 ┆the same process. The ``effecti┆ 0x1120…1140 76 65 20 6c 6f 63 6b 27 27 20 69 73 20 74 68 65 20 75 6e 69 6f 6e 20 6f 66 0a 20 20 20 20 20 61 ┆ve lock'' is the union of a┆ 0x1140…1160 6c 6c 20 6f 66 20 74 68 65 20 6c 6f 63 6b 73 20 6f 62 74 61 69 6e 65 64 20 66 6f 72 20 74 68 65 ┆ll of the locks obtained for the┆ 0x1160…1180 20 66 69 6c 65 2e 20 20 48 6f 77 65 76 65 72 2c 20 6f 6e 6c 79 20 74 68 65 20 53 0a 20 20 20 20 ┆ file. However, only the S ┆ 0x1180…11a0 20 61 6e 64 20 49 58 20 6c 6f 63 6b 73 20 63 6f 6d 70 6c 65 6d 65 6e 74 20 65 61 63 68 20 6f 74 ┆ and IX locks complement each ot┆ 0x11a0…11c0 68 65 72 2e 20 20 49 66 20 61 6e 20 65 78 63 6c 75 73 69 76 65 20 6c 6f 63 6b 20 69 73 0a 20 20 ┆her. If an exclusive lock is ┆ 0x11c0…11e0 20 20 20 68 65 6c 64 2c 20 6e 6f 20 6f 74 68 65 72 20 6c 6f 63 6b 73 20 61 72 65 20 67 72 61 6e ┆ held, no other locks are gran┆ 0x11e0…1200 74 65 64 20 77 68 69 6c 65 20 74 68 65 20 6c 6f 63 6b 20 69 73 20 68 65 6c 64 2e 0a 20 20 20 20 ┆ted while the lock is held. ┆ 0x1200…1220 20 54 68 65 20 65 78 63 6c 75 73 69 76 65 20 6c 6f 63 6b 20 69 73 20 6e 6f 74 20 67 72 61 6e 74 ┆ The exclusive lock is not grant┆ 0x1220…1240 65 64 20 77 68 69 6c 65 20 61 6e 79 20 6f 74 68 65 72 20 6c 6f 63 6b 20 69 73 0a 20 20 20 20 20 ┆ed while any other lock is ┆ 0x1240…1260 68 65 6c 64 20 6f 6e 20 74 68 65 20 66 69 6c 65 2e 0a 0a 20 20 20 20 20 4c 6f 63 6b 73 20 61 72 ┆held on the file. Locks ar┆ 0x1260…1280 65 20 6d 61 69 6e 74 61 69 6e 65 64 20 6f 6e 20 70 65 72 2d 70 72 6f 63 65 73 73 20 61 6e 64 20 ┆e maintained on per-process and ┆ 0x1280…12a0 70 65 72 2d 64 69 73 6b 2d 66 69 6c 65 20 62 61 73 69 73 2e 0a 20 20 20 20 20 4d 75 6c 74 69 70 ┆per-disk-file basis. Multip┆ 0x12a0…12c0 6c 65 20 72 65 66 65 72 65 6e 63 65 73 20 74 6f 20 61 20 73 69 6e 67 6c 65 20 6c 6f 63 6b 20 72 ┆le references to a single lock r┆ 0x12c0…12e0 65 73 75 6c 74 20 66 72 6f 6d 20 65 69 74 68 65 72 0a 20 20 20 20 20 66 69 6c 65 73 20 77 69 74 ┆esult from either files wit┆ 0x12e0…1300 68 20 6d 75 6c 74 69 70 6c 65 20 5f 08 6f 5f 08 70 5f 08 65 5f 08 6e 20 63 61 6c 6c 73 20 6f 75 ┆h multiple _ o_ p_ e_ n calls ou┆ 0x1300…1320 74 73 74 61 6e 64 69 6e 67 2c 20 6f 72 20 66 69 6c 65 20 64 65 73 63 72 69 70 2d 0a 20 20 20 20 ┆tstanding, or file descrip- ┆ 0x1320…1340 20 74 6f 72 73 20 64 75 70 6c 69 63 61 74 65 64 20 77 69 74 68 20 74 68 65 20 5f 08 64 5f 08 75 ┆ tors duplicated with the _ d_ u┆ 0x1340…1360 5f 08 70 20 63 61 6c 6c 2e 20 20 28 54 68 69 73 20 69 73 20 69 6e 73 74 65 61 64 20 6f 66 20 6d ┆_ p call. (This is instead of m┆ 0x1360…1380 75 6c 2d 0a 20 20 20 20 20 74 69 70 6c 65 20 69 6e 73 74 61 6e 63 65 73 20 6f 66 20 61 20 6c 6f ┆ul- tiple instances of a lo┆ 0x1380…13a0 63 6b 2e 29 0a 20 20 20 20 20 44 6f 77 6e 67 72 61 64 69 6e 67 20 74 68 65 20 6c 6f 63 6b 20 6f ┆ck.) Downgrading the lock o┆ 0x13a0…13c0 6e 20 61 6e 79 20 73 75 63 68 20 64 65 73 63 72 69 70 74 6f 72 20 72 65 73 75 6c 74 73 20 69 6e ┆n any such descriptor results in┆ 0x13c0…13e0 20 74 68 65 0a 20 20 20 20 20 6c 6f 63 6b 20 62 65 69 6e 67 20 64 6f 77 6e 67 72 61 64 65 64 20 ┆ the lock being downgraded ┆ 0x13e0…1400 66 6f 72 20 61 6c 6c 20 64 65 73 63 72 69 70 74 6f 72 73 2e 0a 20 20 20 20 20 41 20 5f 08 63 5f ┆for all descriptors. A _ c_┆ 0x1400…1420 08 6c 5f 08 6f 5f 08 73 5f 08 65 20 63 61 6c 6c 20 6f 6e 20 6f 6e 65 20 73 75 63 68 20 64 65 73 ┆ l_ o_ s_ e call on one such des┆ 0x1420…1440 63 72 69 70 74 6f 72 20 72 65 73 75 6c 74 73 20 69 6e 20 61 6e 79 20 72 65 6d 61 69 6e 69 6e 67 ┆criptor results in any remaining┆ 0x1440…1460 0a 20 20 20 20 20 64 65 73 63 72 69 70 74 6f 72 73 20 72 65 74 61 69 6e 69 6e 67 20 74 68 65 20 ┆ descriptors retaining the ┆ 0x1460…1480 68 69 67 68 65 73 74 2d 6c 6f 63 6b 20 73 74 61 74 65 20 6f 62 74 61 69 6e 65 64 2e 20 20 54 68 ┆highest-lock state obtained. Th┆ 0x1480…14a0 65 0a 20 20 20 20 20 6c 6f 63 6b 20 69 73 20 6e 6f 74 20 64 6f 77 6e 67 72 61 64 65 64 2e 20 20 ┆e lock is not downgraded. ┆ 0x14a0…14c0 54 68 65 20 6c 6f 63 6b 20 69 73 20 72 65 6d 6f 76 65 64 20 6f 6e 20 74 68 65 20 6c 61 73 74 0a ┆The lock is removed on the last ┆ 0x14c0…14e0 20 20 20 20 20 63 6c 6f 73 65 2e 0a 0a 20 20 20 20 20 43 08 43 08 43 08 43 68 08 68 08 68 08 68 ┆ close. C C C Ch h h h┆ 0x14e0…1500 61 08 61 08 61 08 61 6e 08 6e 08 6e 08 6e 67 08 67 08 67 08 67 69 08 69 08 69 08 69 6e 08 6e 08 ┆a a a an n n ng g g gi i i in n ┆ 0x1500…1520 6e 08 6e 67 08 67 08 67 08 67 20 74 08 74 08 74 08 74 68 08 68 08 68 08 68 65 08 65 08 65 08 65 ┆n ng g g g t t t th h h he e e e┆ 0x1520…1540 20 4c 08 4c 08 4c 08 4c 6f 08 6f 08 6f 08 6f 63 08 63 08 63 08 63 6b 08 6b 08 6b 08 6b 20 54 08 ┆ L L L Lo o o oc c c ck k k k T ┆ 0x1540…1560 54 08 54 08 54 79 08 79 08 79 08 79 70 08 70 08 70 08 70 65 08 65 08 65 08 65 2e 08 2e 08 2e 08 ┆T T Ty y y yp p p pe e e e. . . ┆ 0x1560…1580 2e 20 20 41 20 70 72 6f 67 72 61 6d 20 6d 61 79 20 63 68 61 6e 67 65 20 74 68 65 20 74 79 70 65 ┆. A program may change the type┆ 0x1580…15a0 20 6f 66 0a 20 20 20 20 20 6c 6f 63 6b 20 69 74 20 68 6f 6c 64 73 20 6f 6e 20 61 20 64 65 73 63 ┆ of lock it holds on a desc┆ 0x15a0…15c0 72 69 70 74 6f 72 20 75 73 69 6e 67 20 74 68 65 20 5f 08 66 5f 08 6c 5f 08 6f 5f 08 63 5f 08 6b ┆riptor using the _ f_ l_ o_ c_ k┆ 0x15c0…15e0 20 63 61 6c 6c 2e 20 20 4f 6e 6c 79 0a 20 20 20 20 20 74 68 65 20 53 20 61 6e 64 20 58 20 6c 6f ┆ call. Only the S and X lo┆ 0x15e0…1600 63 6b 73 20 63 61 6e 20 62 65 20 61 66 66 65 63 74 65 64 20 62 79 20 5f 08 66 5f 08 6c 5f 08 6f ┆cks can be affected by _ f_ l_ o┆ 0x1600…1620 5f 08 63 5f 08 6b 3b 20 74 68 65 20 49 53 20 61 6e 64 20 49 58 0a 20 20 20 20 20 72 65 71 75 69 ┆_ c_ k; the IS and IX requi┆ 0x1620…1640 72 65 20 74 68 61 74 20 74 68 65 20 66 69 6c 65 20 62 65 20 63 6c 6f 73 65 64 20 74 6f 20 63 68 ┆re that the file be closed to ch┆ 0x1640…1660 61 6e 67 65 20 74 68 65 20 6c 6f 63 6b 73 2e 0a 0a 20 20 20 20 20 50 72 6f 63 65 73 73 65 73 20 ┆ange the locks. Processes ┆ 0x1660…1680 74 68 61 74 20 61 72 65 20 6e 6f 74 20 69 6e 20 74 72 61 6e 73 61 63 74 69 6f 6e 20 6d 6f 64 65 ┆that are not in transaction mode┆ 0x1680…16a0 20 63 61 6e 20 70 65 72 66 6f 72 6d 20 6c 6f 63 6b 0a 20 20 20 20 20 63 68 61 6e 67 65 73 20 77 ┆ can perform lock changes w┆ 0x16a0…16c0 69 74 68 6f 75 74 20 72 65 73 74 72 69 63 74 69 6f 6e 2e 0a 0a 20 20 20 20 20 50 72 6f 63 65 73 ┆ithout restriction. Proces┆ 0x16c0…16e0 73 65 73 20 69 6e 20 74 72 61 6e 73 61 63 74 69 6f 6e 20 6d 6f 64 65 20 75 73 65 20 74 77 6f 2d ┆ses in transaction mode use two-┆ 0x16e0…1700 70 68 61 73 65 20 6c 6f 63 6b 69 6e 67 3a 20 6c 6f 63 6b 73 0a 20 20 20 20 20 63 61 6e 20 62 65 ┆phase locking: locks can be┆ 0x1700…1720 20 5f 08 75 5f 08 70 5f 08 67 5f 08 72 5f 08 61 5f 08 64 5f 08 65 5f 08 64 20 77 69 74 68 6f 75 ┆ _ u_ p_ g_ r_ a_ d_ e_ d withou┆ 0x1720…1740 74 20 72 65 73 74 72 69 63 74 69 6f 6e 2c 20 62 75 74 20 61 6c 6c 20 64 6f 77 6e 67 72 61 64 65 ┆t restriction, but all downgrade┆ 0x1740…1760 73 20 61 72 65 0a 20 20 20 20 20 5f 08 64 5f 08 65 5f 08 66 5f 08 65 5f 08 72 5f 08 72 5f 08 65 ┆s are _ d_ e_ f_ e_ r_ r_ e┆ 0x1760…1780 5f 08 64 20 75 6e 74 69 6c 20 74 68 65 20 74 72 61 6e 73 61 63 74 69 6f 6e 20 63 6f 6d 6d 69 74 ┆_ d until the transaction commit┆ 0x1780…17a0 73 2e 20 20 49 66 20 61 20 74 72 61 6e 73 61 63 74 69 6f 6e 0a 20 20 20 20 20 61 62 6f 72 74 73 ┆s. If a transaction aborts┆ 0x17a0…17c0 2c 20 74 68 65 20 6c 6f 63 6b 20 73 74 61 74 65 20 6f 66 20 65 61 63 68 20 66 69 6c 65 20 64 65 ┆, the lock state of each file de┆ 0x17c0…17e0 73 63 72 69 70 74 6f 72 20 69 73 20 72 65 73 74 6f 72 65 64 0a 20 20 20 20 20 74 6f 20 69 74 73 ┆scriptor is restored to its┆ 0x17e0…1800 20 73 74 61 74 65 20 61 74 20 74 68 65 20 62 65 67 69 6e 6e 69 6e 67 20 6f 66 20 74 68 65 20 74 ┆ state at the beginning of the t┆ 0x1800…1820 72 61 6e 73 61 63 74 69 6f 6e 2e 0a 0a 20 20 20 20 20 54 68 65 20 63 61 6c 6c 20 69 73 20 72 65 ┆ransaction. The call is re┆ 0x1820…1840 73 74 61 72 74 65 64 20 61 75 74 6f 6d 61 74 69 63 61 6c 6c 79 20 69 66 20 74 68 65 20 73 69 67 ┆started automatically if the sig┆ 0x1840…1860 6e 61 6c 20 64 65 6c 69 76 65 72 79 0a 20 20 20 20 20 63 61 75 73 65 73 20 70 72 65 6d 61 74 75 ┆nal delivery causes prematu┆ 0x1860…1880 72 65 20 74 65 72 6d 69 6e 61 74 69 6f 6e 2e 0a 0a 20 20 20 20 20 46 08 46 08 46 08 46 6f 08 6f ┆re termination. F F F Fo o┆ 0x1880…18a0 08 6f 08 6f 72 08 72 08 72 08 72 6b 08 6b 08 6b 08 6b 73 08 73 08 73 08 73 0a 20 20 20 20 20 54 ┆ o or r r rk k k ks s s s T┆ 0x18a0…18c0 68 65 20 66 69 6c 65 2d 6c 6f 63 6b 20 73 74 61 74 65 20 69 6e 20 74 68 65 20 70 61 72 65 6e 74 ┆he file-lock state in the parent┆ 0x18c0…18e0 20 70 72 6f 63 65 73 73 20 64 65 74 65 72 6d 69 6e 65 73 20 62 6f 74 68 0a 20 20 20 20 20 74 68 ┆ process determines both th┆ 0x18e0…1900 65 20 63 68 69 6c 64 27 73 20 6c 6f 63 6b 20 73 74 61 74 65 20 61 6e 64 20 77 68 65 74 68 65 72 ┆e child's lock state and whether┆ 0x1900…1920 20 74 68 65 20 64 65 73 63 72 69 70 74 6f 72 20 69 73 20 69 6e 68 65 72 2d 0a 20 20 20 20 20 69 ┆ the descriptor is inher- i┆ […truncated at 200 lines…]