Changes

481 bytes removed ,  09:49, 3 December 2014
no edit summary
Line 19: Line 19:  
So after <code>open()</code> (or some other, see below) system call there will be this chain in the memory
 
So after <code>open()</code> (or some other, see below) system call there will be this chain in the memory
   −
<pre>
+
[[File:Dumping_files-001.svg|thumb|center]]
+------+
  −
+ Task +-----+
  −
+------+    |
  −
            v
  −
          +------------------------------+
  −
          | File Descriptors Table (FDT) |
  −
          +------------------------------+
  −
          |  |  | 2 |      ...    |  |
  −
          +------------------------------+
  −
                    |
  −
                    |
  −
                    |      +------+    +--------+    +-------+
  −
                    +----->| File |--->| Dentry |--->| Inode |
  −
                            +------+    +--------+    +-------+
  −
</pre>
      
The File object can be referenced by more than on FDT, e.g. when a task calls <code>fork()</code> the child one gets new FDT, but it references the same Files as the parent does, i.e. Files become shared objects.
 
The File object can be referenced by more than on FDT, e.g. when a task calls <code>fork()</code> the child one gets new FDT, but it references the same Files as the parent does, i.e. Files become shared objects.