Subversion Repositories HelenOS

Rev

Rev 3628 | Rev 3633 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3628 Rev 3629
Line 92... Line 92...
92
        (node->idx->pdi * sizeof(fat_dentry_t)) / bps, BLOCK_FLAGS_NONE);
92
        (node->idx->pdi * sizeof(fat_dentry_t)) / bps, BLOCK_FLAGS_NONE);
93
 
93
 
94
    d = ((fat_dentry_t *)b->data) + (node->idx->pdi % dps);
94
    d = ((fat_dentry_t *)b->data) + (node->idx->pdi % dps);
95
 
95
 
96
    d->firstc = host2uint16_t_le(node->firstc);
96
    d->firstc = host2uint16_t_le(node->firstc);
97
    if (node->type == FAT_FILE)
97
    if (node->type == FAT_FILE) {
98
        d->size = host2uint32_t_le(node->size);
98
        d->size = host2uint32_t_le(node->size);
-
 
99
    } else if (node->type == FAT_DIRECTORY) {
-
 
100
        d->attr = FAT_ATTR_SUBDIR;
-
 
101
    }
-
 
102
   
99
    /* TODO: update other fields? (e.g time fields, attr field) */
103
    /* TODO: update other fields? (e.g time fields) */
100
   
104
   
101
    b->dirty = true;        /* need to sync block */
105
    b->dirty = true;        /* need to sync block */
102
    block_put(b);
106
    block_put(b);
103
}
107
}
104
 
108