Changeset 7fff5eab in mainline for uspace/srv/vfs/vfs_open.c


Ignore:
Timestamp:
2008-01-08T20:38:59Z (17 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
67f63c4
Parents:
752ccee
Message:

Management of the cached VFS node size.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/vfs/vfs_open.c

    r752ccee r7fff5eab  
    5858        int flags = IPC_GET_ARG1(*request);
    5959        int mode = IPC_GET_ARG2(*request);
    60         size_t size;
     60        size_t len;
    6161
    6262        ipc_callid_t callid;
    6363
    64         if (!ipc_data_write_receive(&callid, &size)) {
     64        if (!ipc_data_write_receive(&callid, &len)) {
    6565                ipc_answer_0(callid, EINVAL);
    6666                ipc_answer_0(rid, EINVAL);
     
    7474         * directly into the PLB using some kind of a callback.
    7575         */
    76         char *path = malloc(size);
     76        char *path = malloc(len);
    7777       
    7878        if (!path) {
     
    8383
    8484        int rc;
    85         if ((rc = ipc_data_write_finalize(callid, path, size))) {
     85        if ((rc = ipc_data_write_finalize(callid, path, len))) {
    8686                ipc_answer_0(rid, rc);
    8787                free(path);
     
    100100         */
    101101        vfs_triplet_t triplet;
    102         rc = vfs_lookup_internal(path, size, &triplet, NULL);
     102        size_t size;
     103        rc = vfs_lookup_internal(path, len, &triplet, &size, NULL);
    103104        if (rc) {
    104105                rwlock_reader_unlock(&namespace_rwlock);
     
    113114        free(path);
    114115
    115         vfs_node_t *node = vfs_node_get(&triplet);
     116        vfs_node_t *node = vfs_node_get(&triplet, size);
    116117        rwlock_reader_unlock(&namespace_rwlock);
    117118
Note: See TracChangeset for help on using the changeset viewer.