DataMuseum.dk

Presents historical artifacts from the history of:

RC9000

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about RC9000

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download
Index: c

⟦61c86a3b9⟧

    Length: 5355 (0x14eb)
    Names: »close.2«

Derivation

└─⟦50656ff4a⟧ Bits:30010538 TX 3.1 Coldstart
    └─⟦bbf173f5c⟧ »0004« 
        └─⟦this⟧ »./usr/man/cat2/close.2« 

Default Hex Dump

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 63 6c 6f 73 65 28 32 29 0a 0a 0a 0a   ┆s                   close(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 63 6c 6f 73 65 20 2d 20 63 6c 6f 73 65 20 61 20 66 69 6c 65 20 64 65 73 63 72 69 70 74 6f   ┆  close - close a file descripto┆
0x00a0…00c0 72 0a 0a 53 08 53 08 53 08 53 59 08 59 08 59 08 59 4e 08 4e 08 4e 08 4e 54 08 54 08 54 08 54 41   ┆r  S S S SY Y Y YN N N NT T T TA┆
0x00c0…00e0 08 41 08 41 08 41 58 08 58 08 58 08 58 0a 20 20 20 20 20 69 08 69 08 69 08 69 6e 08 6e 08 6e 08   ┆ A A AX X X X      i i i in n n ┆
0x00e0…0100 6e 74 08 74 08 74 08 74 20 63 08 63 08 63 08 63 6c 08 6c 08 6c 08 6c 6f 08 6f 08 6f 08 6f 73 08   ┆nt t t t c c c cl l l lo o o os ┆
0x0100…0120 73 08 73 08 73 65 08 65 08 65 08 65 20 28 08 28 08 28 08 28 66 08 66 08 66 08 66 69 08 69 08 69   ┆s s se e e e ( ( ( (f f f fi i i┆
0x0120…0140 08 69 6c 08 6c 08 6c 08 6c 64 08 64 08 64 08 64 65 08 65 08 65 08 65 73 08 73 08 73 08 73 29 08   ┆ il l l ld d d de e e es s s s) ┆
0x0140…0160 29 08 29 08 29 0a 20 20 20 20 20 69 08 69 08 69 08 69 6e 08 6e 08 6e 08 6e 74 08 74 08 74 08 74   ┆) ) )      i i i in n n nt t t t┆
0x0160…0180 20 66 08 66 08 66 08 66 69 08 69 08 69 08 69 6c 08 6c 08 6c 08 6c 64 08 64 08 64 08 64 65 08 65   ┆ f f f fi i i il l l ld d d de e┆
0x0180…01a0 08 65 08 65 73 08 73 08 73 08 73 3b 08 3b 08 3b 08 3b 0a 0a 44 08 44 08 44 08 44 45 08 45 08 45   ┆ e es s s s; ; ; ;  D D D DE E E┆
0x01a0…01c0 08 45 53 08 53 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   ┆ ES S S SC C C CR R R RI I I IP ┆
0x01c0…01e0 50 08 50 08 50 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   ┆P P PT T T TI I I IO O O ON N N ┆
0x01e0…0200 4e 0a 20 20 20 20 20 54 68 65 20 5f 08 63 5f 08 6c 5f 08 6f 5f 08 73 5f 08 65 28 29 20 66 75 6e   ┆N      The _ c_ l_ o_ s_ e() fun┆
0x0200…0220 63 74 69 6f 6e 20 77 69 6c 6c 20 64 65 61 6c 6c 6f 63 61 74 65 20 28 69 2e 65 2e 2c 20 6d 61 6b   ┆ction will deallocate (i.e., mak┆
0x0220…0240 65 20 61 76 61 69 6c 61 62 6c 65 0a 20 20 20 20 20 66 6f 72 20 72 65 74 75 72 6e 20 62 79 20 73   ┆e available      for return by s┆
0x0240…0260 75 62 73 65 71 75 65 6e 74 20 5f 08 6f 5f 08 70 5f 08 65 5f 08 6e 28 29 27 73 20 65 74 63 2e 2c   ┆ubsequent _ o_ p_ e_ n()'s etc.,┆
0x0260…0280 20 65 78 65 63 75 74 65 64 20 62 79 20 74 68 65 20 70 72 6f 2d 0a 20 20 20 20 20 63 65 73 73 29   ┆ executed by the pro-      cess)┆
0x0280…02a0 20 74 68 65 20 66 69 6c 65 20 64 65 73 63 72 69 70 74 6f 72 20 69 6e 64 69 63 61 74 65 64 20 62   ┆ the file descriptor indicated b┆
0x02a0…02c0 79 20 5f 08 66 5f 08 69 5f 08 6c 5f 08 64 5f 08 65 5f 08 73 2e 20 20 41 6c 6c 20 6f 75 74 2d 0a   ┆y _ f_ i_ l_ d_ e_ s.  All out- ┆
0x02c0…02e0 20 20 20 20 20 73 74 61 6e 64 69 6e 67 20 72 65 63 6f 72 64 20 6c 6f 63 6b 73 20 6f 77 6e 65 64   ┆     standing record locks owned┆
0x02e0…0300 20 62 79 20 74 68 65 20 70 72 6f 63 65 73 73 20 6f 6e 20 74 68 65 20 66 69 6c 65 20 61 73 73 6f   ┆ by the process on the file asso┆
0x0300…0320 2d 0a 20 20 20 20 20 63 69 61 74 65 64 20 77 69 74 68 20 74 68 65 20 66 69 6c 65 20 64 65 73 63   ┆-      ciated with the file desc┆
0x0320…0340 72 69 70 74 6f 72 20 77 69 6c 6c 20 62 65 20 72 65 6d 6f 76 65 64 20 28 74 68 61 74 20 69 73 2c   ┆riptor will be removed (that is,┆
0x0340…0360 0a 20 20 20 20 20 75 6e 6c 6f 63 6b 65 64 29 2e 20 20 54 58 20 65 6e 73 75 72 65 73 20 74 68 61   ┆      unlocked).  TX ensures tha┆
0x0360…0380 74 20 61 6c 6c 20 70 68 79 73 69 63 61 6c 20 49 2f 4f 20 69 73 20 63 6f 6d 70 6c 65 74 65 64 0a   ┆t all physical I/O is completed ┆
0x0380…03a0 20 20 20 20 20 62 65 66 6f 72 65 20 64 65 61 6c 6c 6f 63 61 74 69 6e 67 20 74 68 65 20 66 69 6c   ┆     before deallocating the fil┆
0x03a0…03c0 65 20 64 65 73 63 72 69 70 74 6f 72 2e 20 54 68 69 73 20 69 73 20 69 6e 20 63 6f 6e 74 72 61 73   ┆e descriptor. This is in contras┆
0x03c0…03e0 74 0a 20 20 20 20 20 74 6f 20 63 6f 6e 76 65 6e 74 69 6f 6e 61 6c 20 55 4e 49 58 20 73 79 73 74   ┆t      to conventional UNIX syst┆
0x03e0…0400 65 6d 73 2c 20 77 68 69 63 68 20 64 6f 20 6e 6f 74 20 66 6c 75 73 68 20 77 72 69 74 65 73 20 61   ┆ems, which do not flush writes a┆
0x0400…0420 73 0a 20 20 20 20 20 70 61 72 74 20 6f 66 20 5f 08 63 5f 08 6c 5f 08 6f 5f 08 73 5f 08 65 2e 20   ┆s      part of _ c_ l_ o_ s_ e. ┆
0x0420…0440 20 57 68 65 6e 20 5f 08 63 5f 08 6c 5f 08 6f 5f 08 73 5f 08 65 20 69 73 20 63 61 6c 6c 65 64 2c   ┆ When _ c_ l_ o_ s_ e is called,┆
0x0440…0460 20 65 72 72 6f 72 73 20 6d 61 79 20 6f 63 63 75 72 20 66 6f 72 0a 20 20 20 20 20 5f 08 77 5f 08   ┆ errors may occur for      _ w_ ┆
0x0460…0480 72 5f 08 69 5f 08 74 5f 08 65 20 65 72 72 6f 72 73 20 74 68 61 74 20 77 65 72 65 20 75 6e 64 65   ┆r_ i_ t_ e errors that were unde┆
0x0480…04a0 74 65 63 74 65 64 20 62 65 66 6f 72 65 20 74 68 65 20 62 75 66 66 65 72 20 77 61 73 0a 20 20 20   ┆tected before the buffer was    ┆
0x04a0…04c0 20 20 66 6c 75 73 68 65 64 2e 0a 0a 20 20 20 20 20 49 66 20 74 68 65 20 5f 08 63 5f 08 6c 5f 08   ┆  flushed.       If the _ c_ l_ ┆
0x04c0…04e0 6f 5f 08 73 5f 08 65 28 29 20 66 75 6e 63 74 69 6f 6e 20 69 73 20 69 6e 74 65 72 72 75 70 74 65   ┆o_ s_ e() function is interrupte┆
0x04e0…0500 64 20 62 79 20 61 20 73 69 67 6e 61 6c 20 74 68 61 74 20 69 73 0a 20 20 20 20 20 74 6f 20 62 65   ┆d by a signal that is      to be┆
0x0500…0520 20 63 61 75 67 68 74 2c 20 69 74 20 77 69 6c 6c 20 72 65 74 75 72 6e 20 2d 31 20 77 69 74 68 20   ┆ caught, it will return -1 with ┆
0x0520…0540 5f 08 65 5f 08 72 5f 08 72 5f 08 6e 5f 08 6f 20 73 65 74 20 74 6f 20 5b 45 49 4e 54 52 5d 0a 20   ┆_ e_ r_ r_ n_ o set to [EINTR]  ┆
0x0540…0560 20 20 20 20 61 6e 64 20 74 68 65 20 73 74 61 74 65 20 6f 66 20 5f 08 66 5f 08 69 5f 08 6c 5f 08   ┆    and the state of _ f_ i_ l_ ┆
0x0560…0580 64 5f 08 65 5f 08 73 20 69 73 20 75 6e 73 70 65 63 69 66 69 65 64 2e 0a 0a 20 20 20 20 20 57 68   ┆d_ e_ s is unspecified.       Wh┆
0x0580…05a0 65 6e 20 61 6c 6c 20 66 69 6c 65 20 64 65 73 63 72 69 70 74 6f 72 73 20 61 73 73 6f 63 69 61 74   ┆en all file descriptors associat┆
0x05a0…05c0 65 64 20 77 69 74 68 20 61 20 70 69 70 65 20 6f 72 20 46 49 46 4f 0a 20 20 20 20 20 73 70 65 63   ┆ed with a pipe or FIFO      spec┆
0x05c0…05e0 69 61 6c 20 66 69 6c 65 20 68 61 76 65 20 62 65 65 6e 20 63 6c 6f 73 65 64 2c 20 61 6e 79 20 64   ┆ial file have been closed, any d┆
0x05e0…0600 61 74 61 20 72 65 6d 61 69 6e 69 6e 67 20 69 6e 20 74 68 65 0a 20 20 20 20 20 70 69 70 65 20 6f   ┆ata remaining in the      pipe o┆
0x0600…0620 72 20 46 49 46 4f 20 77 69 6c 6c 20 62 65 20 64 69 73 63 61 72 64 65 64 2e 0a 0a 20 20 20 20 20   ┆r FIFO will be discarded.       ┆
0x0620…0640 57 68 65 6e 20 61 6c 6c 20 66 69 6c 65 20 64 65 73 63 72 69 70 74 6f 72 73 20 61 73 73 6f 63 69   ┆When all file descriptors associ┆
0x0640…0660 61 74 65 64 20 77 69 74 68 20 61 6e 20 6f 70 65 6e 20 66 69 6c 65 20 68 61 76 65 0a 20 20 20 20   ┆ated with an open file have     ┆
0x0660…0680 20 62 65 65 6e 20 63 6c 6f 73 65 64 2c 20 74 68 65 20 6f 70 65 6e 20 66 69 6c 65 20 64 65 73 63   ┆ been closed, the open file desc┆
0x0680…06a0 72 69 70 74 69 6f 6e 20 77 69 6c 6c 20 62 65 20 66 72 65 65 64 2e 0a 0a 20 20 20 20 20 49 66 20   ┆ription will be freed.       If ┆
0x06a0…06c0 74 68 65 20 6c 69 6e 6b 20 63 6f 75 6e 74 20 6f 66 20 74 68 65 20 66 69 6c 65 20 69 73 20 7a 65   ┆the link count of the file is ze┆
0x06c0…06e0 72 6f 20 77 68 65 6e 20 61 6c 6c 20 66 69 6c 65 20 64 65 73 63 72 69 70 2d 0a 20 20 20 20 20 74   ┆ro when all file descrip-      t┆
0x06e0…0700 6f 72 73 20 61 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 20 74 68 65 20 66 69 6c 65 20 68 61 76   ┆ors associated with the file hav┆
0x0700…0720 65 20 62 65 65 6e 20 63 6c 6f 73 65 64 2c 20 74 68 65 20 73 70 61 63 65 0a 20 20 20 20 20 6f 63   ┆e been closed, the space      oc┆
0x0720…0740 63 75 70 69 65 64 20 62 79 20 74 68 65 20 66 69 6c 65 20 77 69 6c 6c 20 62 65 20 66 72 65 65 64   ┆cupied by the file will be freed┆
0x0740…0760 20 61 6e 64 20 74 68 65 20 66 69 6c 65 20 77 69 6c 6c 20 6e 6f 0a 20 20 20 20 20 6c 6f 6e 67 65   ┆ and the file will no      longe┆
0x0760…0780 72 20 62 65 20 61 63 63 65 73 73 69 62 6c 65 2e 0a 0a 20 20 20 20 20 46 08 46 08 46 08 46 69 08   ┆r be accessible.       F F F Fi ┆
0x0780…07a0 69 08 69 08 69 6c 08 6c 08 6c 08 6c 65 08 65 08 65 08 65 2d 08 2d 08 2d 08 2d 54 08 54 08 54 08   ┆i i il l l le e e e- - - -T T T ┆
0x07a0…07c0 54 79 08 79 08 79 08 79 70 08 70 08 70 08 70 65 08 65 08 65 08 65 20 43 08 43 08 43 08 43 6f 08   ┆Ty y y yp p p pe e e e C C C Co ┆
0x07c0…07e0 6f 08 6f 08 6f 6e 08 6e 08 6e 08 6e 73 08 73 08 73 08 73 69 08 69 08 69 08 69 64 08 64 08 64 08   ┆o o on n n ns s s si i i id d d ┆
0x07e0…0800 64 65 08 65 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   ┆de e e er r r ra a a at t t ti i┆
0x0800…0820 08 69 08 69 6f 08 6f 08 6f 08 6f 6e 08 6e 08 6e 08 6e 73 08 73 08 73 08 73 0a 20 20 20 20 20 4f   ┆ i io o o on n n ns s s s      O┆
0x0820…0840 70 65 72 61 74 69 6f 6e 20 64 65 70 65 6e 64 73 20 6f 6e 20 74 68 65 20 66 69 6c 65 20 74 79 70   ┆peration depends on the file typ┆
0x0840…0860 65 20 69 6e 20 74 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 63 61 73 65 73 3a 0a 0a 20 20 20 20 20   ┆e in the following cases:       ┆
0x0860…0880 31 29 20 20 46 6f 72 20 61 20 5f 08 73 5f 08 6f 5f 08 63 5f 08 6b 5f 08 65 5f 08 74 20 6f 72 20   ┆1)  For a _ s_ o_ c_ k_ e_ t or ┆
0x0880…08a0 61 6e 20 5f 08 49 5f 08 50 5f 08 43 20 5f 08 63 5f 08 68 5f 08 61 5f 08 6e 5f 08 6e 5f 08 65 5f   ┆an _ I_ P_ C _ c_ h_ a_ n_ n_ e_┆
0x08a0…08c0 08 6c 2c 20 61 73 73 6f 63 69 61 74 65 64 20 6e 61 6d 69 6e 67 20 69 6e 66 6f 72 2d 0a 20 20 20   ┆ l, associated naming infor-    ┆
0x08c0…08e0 20 20 20 20 20 20 6d 61 74 69 6f 6e 20 61 6e 64 20 71 75 65 75 65 64 20 64 61 74 61 20 61 72 65   ┆      mation and queued data are┆
0x08e0…0900 20 64 69 73 63 61 72 64 65 64 2e 20 20 49 66 20 61 6e 20 49 50 43 20 63 68 61 6e 6e 65 6c 0a 20   ┆ discarded.  If an IPC channel  ┆
0x0900…0920 20 20 20 20 20 20 20 20 69 73 20 63 6c 6f 73 65 64 2c 20 61 6e 20 65 6e 64 2d 6f 66 2d 66 69 6c   ┆        is closed, an end-of-fil┆
0x0920…0940 65 20 69 73 20 73 65 6e 74 20 74 6f 20 74 68 65 20 70 61 69 72 65 64 20 70 72 6f 63 65 73 73 2e   ┆e is sent to the paired process.┆
0x0940…0960 0a 0a 20 20 20 20 20 32 29 20 20 46 6f 72 20 66 69 6c 65 73 20 77 69 74 68 20 62 6c 6f 63 6b 2d   ┆       2)  For files with block-┆
0x0960…0980 20 6f 72 20 66 69 6c 65 2d 6c 65 76 65 6c 20 6c 6f 63 6b 73 2c 20 74 68 65 20 6c 6f 63 6b 73 20   ┆ or file-level locks, the locks ┆
0x0980…09a0 61 72 65 0a 20 20 20 20 20 20 20 20 20 72 65 6c 65 61 73 65 64 20 28 75 6e 6c 65 73 73 20 74 68   ┆are          released (unless th┆
0x09a0…09c0 65 20 70 72 6f 67 72 61 6d 20 69 73 20 65 78 65 63 75 74 69 6e 67 20 69 6e 20 74 72 61 6e 73 61   ┆e program is executing in transa┆
0x09c0…09e0 63 74 69 6f 6e 0a 20 20 20 20 20 20 20 20 20 6d 6f 64 65 29 2e 20 20 54 72 61 6e 73 61 63 74 69   ┆ction          mode).  Transacti┆
0x09e0…0a00 6f 6e 2d 6d 6f 64 65 20 70 72 6f 67 72 61 6d 73 20 72 65 74 61 69 6e 20 74 68 65 20 6c 6f 63 6b   ┆on-mode programs retain the lock┆
0x0a00…0a20 73 20 75 6e 74 69 6c 0a 20 20 20 20 20 20 20 20 20 74 68 65 20 74 72 61 6e 73 61 63 74 69 6f 6e   ┆s until          the transaction┆
0x0a20…0a40 20 63 6f 6d 6d 69 74 73 2e 20 20 53 65 65 20 74 68 65 20 5f 08 66 5f 08 6c 5f 08 6f 5f 08 63 5f   ┆ commits.  See the _ f_ l_ o_ c_┆
0x0a40…0a60 08 6b 20 61 6e 64 20 5f 08 6d 5f 08 62 5f 08 6c 5f 08 6f 5f 08 63 5f 08 6b 0a 20 20 20 20 20 20   ┆ k and _ m_ b_ l_ o_ c_ k       ┆
0x0a60…0a80 20 20 20 63 61 6c 6c 73 2e 0a 0a 20 20 20 20 20 33 29 20 20 46 6f 72 20 74 74 79 27 73 2c 20 6e   ┆   calls.       3)  For tty's, n┆
0x0a80…0aa0 6f 6c 6f 67 69 6e 20 6c 69 6e 65 73 2c 20 70 72 69 6e 74 65 72 73 2c 20 61 6e 64 20 72 61 77 20   ┆ologin lines, printers, and raw ┆
0x0aa0…0ac0 64 65 76 69 63 65 73 2c 20 74 68 65 0a 20 20 20 20 20 20 20 20 20 66 69 6c 65 20 64 65 73 63 72   ┆devices, the          file descr┆
0x0ac0…0ae0 69 70 74 6f 72 20 69 73 20 64 65 6c 65 74 65 64 2e 20 20 54 68 65 20 6f 62 6a 65 63 74 20 72 65   ┆iptor is deleted.  The object re┆
0x0ae0…0b00 6d 61 69 6e 73 20 61 63 74 69 76 65 2e 0a 0a 20 20 20 20 20 54 08 54 08 54 08 54 72 08 72 08 72   ┆mains active.       T T T Tr r r┆
0x0b00…0b20 08 72 61 08 61 08 61 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   ┆ ra a a an n n ns s s sa a a ac ┆
0x0b20…0b40 63 08 63 08 63 74 08 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   ┆c c ct t t ti i i io o o on n n ┆
0x0b40…0b60 6e 20 50 08 50 08 50 08 50 72 08 72 08 72 08 72 6f 08 6f 08 6f 08 6f 63 08 63 08 63 08 63 65 08   ┆n P P P Pr r r ro o o oc c c ce ┆
0x0b60…0b80 65 08 65 08 65 73 08 73 08 73 08 73 73 08 73 08 73 08 73 69 08 69 08 69 08 69 6e 08 6e 08 6e 08   ┆e e es s s ss s s si i i in n n ┆
0x0b80…0ba0 6e 67 08 67 08 67 08 67 0a 20 20 20 20 20 49 66 20 5f 08 63 5f 08 6c 5f 08 6f 5f 08 73 5f 08 65   ┆ng g g g      If _ c_ l_ o_ s_ e┆
0x0ba0…0bc0 20 69 73 20 63 61 6c 6c 65 64 20 77 68 69 6c 65 20 61 20 70 72 6f 63 65 73 73 20 69 73 20 69 6e   ┆ is called while a process is in┆
0x0bc0…0be0 20 74 72 61 6e 73 61 63 74 69 6f 6e 20 73 74 61 74 65 2c 0a 20 20 20 20 20 74 68 65 20 63 6c 6f   ┆ transaction state,      the clo┆
0x0be0…0c00 73 65 20 61 63 74 69 6f 6e 20 69 73 20 64 65 66 65 72 72 65 64 20 75 6e 74 69 6c 20 74 68 65 20   ┆se action is deferred until the ┆
0x0c00…0c20 74 72 61 6e 73 61 63 74 69 6f 6e 20 68 61 73 20 63 6f 6d 2d 0a 20 20 20 20 20 70 6c 65 74 65 64   ┆transaction has com-      pleted┆
0x0c20…0c40 20 28 65 69 74 68 65 72 20 63 6f 6d 6d 69 74 20 6f 72 20 61 62 6f 72 74 29 2e 20 20 41 6c 6c 20   ┆ (either commit or abort).  All ┆
0x0c40…0c60 6c 6f 63 6b 73 20 61 72 65 20 68 65 6c 64 20 75 6e 74 69 6c 0a 20 20 20 20 20 74 68 65 20 65 6e   ┆locks are held until      the en┆
0x0c60…0c80 64 2d 6f 66 2d 74 72 61 6e 73 61 63 74 69 6f 6e 2e 20 20 49 66 20 74 68 65 20 75 73 65 72 20 72   ┆d-of-transaction.  If the user r┆
0x0c80…0ca0 65 6f 70 65 6e 73 20 74 68 65 20 66 69 6c 65 20 62 65 66 6f 72 65 0a 20 20 20 20 20 65 6e 64 69   ┆eopens the file before      endi┆
0x0ca0…0cc0 6e 67 20 74 68 65 20 74 72 61 6e 73 61 63 74 69 6f 6e 2c 20 74 68 65 20 66 69 6c 65 20 61 70 70   ┆ng the transaction, the file app┆
0x0cc0…0ce0 65 61 72 73 20 61 73 20 77 72 69 74 74 65 6e 0a 20 20 20 20 20 28 61 6c 74 68 6f 75 67 68 20 61   ┆ears as written      (although a┆
0x0ce0…0d00 20 6e 65 77 20 64 65 73 63 72 69 70 74 6f 72 20 69 73 20 61 73 73 6f 63 69 61 74 65 64 20 77 69   ┆ new descriptor is associated wi┆
0x0d00…0d20 74 68 20 74 68 65 20 66 69 6c 65 29 2e 0a 0a 0a 0a 0a 0a 0a 20 20 20 20 20 46 6f 72 20 61 6e 20   ┆th the file).            For an ┆
0x0d20…0d40 4d 58 49 50 43 20 63 68 61 6e 6e 65 6c 20 69 6e 20 74 72 61 6e 73 61 63 74 69 6f 6e 2c 20 74 68   ┆MXIPC channel in transaction, th┆
0x0d40…0d60 65 20 61 63 74 69 6f 6e 20 69 73 20 74 68 65 20 73 61 6d 65 0a 20 20 20 20 20 61 73 20 63 6c 6f   ┆e action is the same      as clo┆
0x0d60…0d80 73 69 6e 67 20 61 6e 20 6f 72 64 69 6e 61 72 79 20 66 69 6c 65 3a 20 20 74 68 65 20 63 6c 6f 73   ┆sing an ordinary file:  the clos┆
0x0d80…0da0 65 20 69 73 20 64 65 66 65 72 72 65 64 20 75 6e 74 69 6c 0a 20 20 20 20 20 74 68 65 20 65 6e 64   ┆e is deferred until      the end┆
0x0da0…0dc0 20 6f 66 20 74 68 65 20 74 72 61 6e 73 61 63 74 69 6f 6e 2e 20 20 46 6f 72 20 61 20 54 58 49 50   ┆ of the transaction.  For a TXIP┆
0x0dc0…0de0 43 20 63 68 61 6e 6e 65 6c 2c 20 61 20 73 65 72 76 65 72 0a 20 20 20 20 20 63 61 6e 20 65 78 69   ┆C channel, a server      can exi┆
0x0de0…0e00 74 20 74 72 61 6e 73 61 63 74 69 6f 6e 20 6d 6f 64 65 20 62 79 20 63 61 6c 6c 69 6e 67 20 5f 08   ┆t transaction mode by calling _ ┆
0x0e00…0e20 63 5f 08 6c 5f 08 6f 5f 08 73 5f 08 65 20 6f 6e 20 74 68 65 20 54 58 49 50 43 0a 20 20 20 20 20   ┆c_ l_ o_ s_ e on the TXIPC      ┆
0x0e20…0e40 63 68 61 6e 6e 65 6c 20 6f 76 65 72 20 77 68 69 63 68 20 69 74 20 68 61 73 20 6a 6f 69 6e 65 64   ┆channel over which it has joined┆
0x0e40…0e60 20 69 6e 20 61 20 74 72 61 6e 73 61 63 74 69 6f 6e 2e 0a 0a 52 08 52 08 52 08 52 45 08 45 08 45   ┆ in a transaction.  R R R RE E E┆
0x0e60…0e80 08 45 54 08 54 08 54 08 54 55 08 55 08 55 08 55 52 08 52 08 52 08 52 4e 08 4e 08 4e 08 4e 20 56   ┆ ET T T TU U U UR R R RN N N N V┆
0x0e80…0ea0 08 56 08 56 08 56 41 08 41 08 41 08 41 4c 08 4c 08 4c 08 4c 55 08 55 08 55 08 55 45 08 45 08 45   ┆ V V VA A A AL L L LU U U UE E E┆
0x0ea0…0ec0 08 45 0a 20 20 20 20 20 55 70 6f 6e 20 73 75 63 63 65 73 73 66 75 6c 20 63 6f 6d 70 6c 65 74 69   ┆ E      Upon successful completi┆
0x0ec0…0ee0 6f 6e 2c 20 61 20 76 61 6c 75 65 20 6f 66 20 30 20 69 73 20 72 65 74 75 72 6e 65 64 2e 20 20 4f   ┆on, a value of 0 is returned.  O┆
0x0ee0…0f00 74 68 2d 0a 20 20 20 20 20 65 72 77 69 73 65 2c 20 61 20 76 61 6c 75 65 20 6f 66 20 2d 31 20 69   ┆th-      erwise, a value of -1 i┆
0x0f00…0f20 73 20 72 65 74 75 72 6e 65 64 20 61 6e 64 20 5f 08 65 5f 08 72 5f 08 72 5f 08 6e 5f 08 6f 20 69   ┆s returned and _ e_ r_ r_ n_ o i┆
0x0f20…0f40 73 20 73 65 74 20 74 6f 20 69 6e 64 69 2d 0a 20 20 20 20 20 63 61 74 65 20 74 68 65 20 65 72 72   ┆s set to indi-      cate the err┆
0x0f40…0f60 6f 72 2e 0a 0a 45 08 45 08 45 08 45 52 08 52 08 52 08 52 52 08 52 08 52 08 52 4f 08 4f 08 4f 08   ┆or.  E E E ER R R RR R R RO O O ┆
0x0f60…0f80 4f 52 08 52 08 52 08 52 53 08 53 08 53 08 53 0a 20 20 20 20 20 5f 08 63 5f 08 6c 5f 08 6f 5f 08   ┆OR R R RS S S S      _ c_ l_ o_ ┆
0x0f80…0fa0 73 5f 08 65 20 77 69 6c 6c 20 66 61 69 6c 20 69 66 20 74 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20   ┆s_ e will fail if the following ┆
0x0fa0…0fc0 69 73 20 74 72 75 65 0a 0a 20 20 20 20 20 5b 45 42 41 44 46 5d 20 20 20 20 20 20 20 20 45 69 74   ┆is true       [EBADF]        Eit┆
0x0fc0…0fe0 68 65 72 20 5f 08 66 5f 08 69 5f 08 6c 5f 08 64 5f 08 65 5f 08 73 20 69 73 20 6e 6f 74 20 61 20   ┆her _ f_ i_ l_ d_ e_ s is not a ┆
0x0fe0…1000 76 61 6c 69 64 20 6f 70 65 6e 20 66 69 6c 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20   ┆valid open file                 ┆
0x1000…1020 20 20 20 20 64 65 73 63 72 69 70 74 6f 72 2c 20 6f 72 20 5f 08 66 5f 08 69 5f 08 6c 5f 08 64 5f   ┆    descriptor, or _ f_ i_ l_ d_┆
0x1020…1040 08 65 5f 08 73 20 63 61 6e 6e 6f 74 20 62 65 20 63 6c 6f 73 65 64 20 69 6e 73 69 64 65 0a 20 20   ┆ e_ s cannot be closed inside   ┆
0x1040…1060 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 20 74 72 61 6e 73 61 63 74 69 6f 6e 20   ┆                  a transaction ┆
0x1060…1080 62 65 63 61 75 73 65 20 69 74 20 77 61 73 20 6f 70 65 6e 65 64 20 6f 75 74 73 69 64 65 0a 20 20   ┆because it was opened outside   ┆
0x1080…10a0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 65 20 74 72 61 73 6e 61 63 74 69 6f   ┆                  the trasnactio┆
0x10a0…10c0 6e 2e 0a 0a 20 20 20 20 20 5b 45 49 4e 54 52 5d 20 20 20 20 20 20 20 20 54 68 65 20 5f 08 63 5f   ┆n.       [EINTR]        The _ c_┆
0x10c0…10e0 08 6c 5f 08 6f 5f 08 73 5f 08 65 28 29 20 66 75 6e 63 74 69 6f 6e 20 77 61 73 20 69 6e 74 65 72   ┆ l_ o_ s_ e() function was inter┆
0x10e0…1100 72 75 70 74 65 64 20 62 79 20 61 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20   ┆rupted by a                     ┆
0x1100…1120 73 69 67 6e 61 6c 2e 0a 0a 20 20 20 20 20 5b 45 52 45 54 52 59 5d 20 20 20 20 20 20 20 54 68 65   ┆signal.       [ERETRY]       The┆
0x1120…1140 20 66 69 6c 65 20 72 65 66 65 72 65 6e 63 65 64 20 62 79 20 5f 08 66 5f 08 69 5f 08 6c 5f 08 64   ┆ file referenced by _ f_ i_ l_ d┆
0x1140…1160 5f 08 65 5f 08 73 20 77 61 73 20 6f 70 65 6e 65 64 20 62 79 20 61 0a 20 20 20 20 20 20 20 20 20   ┆_ e_ s was opened by a          ┆
0x1160…1180 20 20 20 20 20 20 20 20 20 20 20 63 6c 69 65 6e 74 20 62 65 66 6f 72 65 20 62 65 67 69 6e 6e 69   ┆           client before beginni┆
0x1180…11a0 6e 67 20 61 20 74 72 61 6e 73 61 63 74 69 6f 6e 2e 20 54 68 65 0a 20 20 20 20 20 20 20 20 20 20   ┆ng a transaction. The           ┆
0x11a0…11c0 20 20 20 20 20 20 20 20 20 20 66 69 6c 65 20 6d 75 73 74 20 62 65 20 63 6c 6f 73 65 64 20 61 66   ┆          file must be closed af┆
0x11c0…11e0 74 65 72 20 74 68 65 20 74 72 61 6e 73 61 63 74 69 6f 6e 0a 20 20 20 20 20 20 20 20 20 20 20 20   ┆ter the transaction             ┆
0x11e0…1200 20 20 20 20 20 20 20 20 63 6f 6d 70 6c 65 74 65 73 2e 20 54 68 69 73 20 63 61 6e 20 68 61 70 70   ┆        completes. This can happ┆
0x1200…1220 65 6e 20 77 68 65 6e 20 61 20 73 65 72 76 65 72 20 70 72 6f 2d 0a 20 20 20 20 20 20 20 20 20 20   ┆en when a server pro-           ┆
0x1220…1240 20 20 20 20 20 20 20 20 20 20 63 65 73 73 20 65 78 69 74 73 20 74 72 61 6e 73 61 63 74 69 6f 6e   ┆          cess exits transaction┆
0x1240…1260 20 6d 6f 64 65 2c 20 62 75 74 20 74 68 65 20 66 69 6c 65 20 69 73 0a 20 20 20 20 20 20 20 20 20   ┆ mode, but the file is          ┆
0x1260…1280 20 20 20 20 20 20 20 20 20 20 20 73 74 69 6c 6c 20 69 6e 76 6f 6c 76 65 64 20 69 6e 20 74 68 65   ┆           still involved in the┆
0x1280…12a0 20 74 72 61 6e 73 61 63 74 69 6f 6e 2e 0a 0a 53 08 53 08 53 08 53 45 08 45 08 45 08 45 45 08 45   ┆ transaction.  S S S SE E E EE E┆
0x12a0…12c0 08 45 08 45 20 41 08 41 08 41 08 41 4c 08 4c 08 4c 08 4c 53 08 53 08 53 08 53 4f 08 4f 08 4f 08   ┆ E E A A A AL L L LS S S SO O O ┆
0x12c0…12e0 4f 0a 20 20 20 20 20 53 79 73 74 65 6d 20 43 61 6c 6c 73 20 28 32 29 3a 20 20 6f 70 65 6e 2c 20   ┆O      System Calls (2):  open, ┆
0x12e0…1300 66 6f 70 65 6e 2c 20 66 63 6c 6f 73 65 2e 0a 0a 41 08 41 08 41 08 41 50 08 50 08 50 08 50 50 08   ┆fopen, fclose.  A A A AP P P PP ┆
0x1300…1320 50 08 50 08 50 4c 08 4c 08 4c 08 4c 49 08 49 08 49 08 49 43 08 43 08 43 08 43 41 08 41 08 41 08   ┆P P PL L L LI I I IC C C CA A A ┆
0x1320…1340 41 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 20 55 08   ┆AT T T TI I I IO O O ON N N N U ┆
0x1340…1360 55 08 55 08 55 53 08 53 08 53 08 53 41 08 41 08 41 08 41 47 08 47 08 47 08 47 45 08 45 08 45 08   ┆U U US S S SA A A AG G G GE E E ┆
0x1360…1380 45 0a 20 20 20 20 20 4e 6f 72 6d 61 6c 6c 79 2c 20 61 70 70 6c 69 63 61 74 69 6f 6e 73 20 73 68   ┆E      Normally, applications sh┆
0x1380…13a0 6f 75 6c 64 20 6f 6e 6c 79 20 75 73 65 20 74 68 65 20 5f 08 73 5f 08 74 5f 08 64 5f 08 69 5f 08   ┆ould only use the _ s_ t_ d_ i_ ┆
0x13a0…13c0 6f 20 72 6f 75 74 69 6e 65 73 20 74 6f 0a 20 20 20 20 20 6f 70 65 6e 2c 20 63 6c 6f 73 65 2c 20   ┆o routines to      open, close, ┆
0x13c0…13e0 72 65 61 64 20 61 6e 64 20 77 72 69 74 65 20 66 69 6c 65 73 2e 20 20 54 68 75 73 2c 20 61 6e 20   ┆read and write files.  Thus, an ┆
0x13e0…1400 61 70 70 6c 69 63 61 74 69 6f 6e 0a 20 20 20 20 20 74 68 61 74 20 68 61 64 20 75 73 65 64 20 74   ┆application      that had used t┆
0x1400…1420 68 65 20 5f 08 73 5f 08 74 5f 08 64 5f 08 69 5f 08 6f 20 72 6f 75 74 69 6e 65 20 5f 08 66 5f 08   ┆he _ s_ t_ d_ i_ o routine _ f_ ┆
0x1420…1440 6f 5f 08 70 5f 08 65 5f 08 6e 20 74 6f 20 6f 70 65 6e 20 61 20 66 69 6c 65 20 77 6f 75 6c 64 0a   ┆o_ p_ e_ n to open a file would ┆
0x1440…1460 20 20 20 20 20 75 73 65 20 74 68 65 20 63 6f 72 72 65 73 70 6f 6e 64 69 6e 67 20 5f 08 66 5f 08   ┆     use the corresponding _ f_ ┆
0x1460…1480 63 5f 08 6c 5f 08 6f 5f 08 73 5f 08 65 20 72 6f 75 74 69 6e 65 20 72 61 74 68 65 72 20 74 68 61   ┆c_ l_ o_ s_ e routine rather tha┆
0x1480…14a0 6e 20 5f 08 63 5f 08 6c 5f 08 6f 5f 08 73 5f 08 65 2e 0a 0a 44 65 63 65 6d 62 65 72 20 31 39 39   ┆n _ c_ l_ o_ s_ e.  December 199┆
0x14a0…14c0 30 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 54 58 20 50   ┆0                           TX P┆
0x14c0…14e0 72 6f 67 72 61 6d 6d 65 72 27 73 20 52 65 66 65 72 65 6e 63 65 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a   ┆rogrammer's Reference           ┆
0x14e0…14eb 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a                                                                  ┆           ┆