Changeset c990ee6 in mainline for uspace/srv/vfs/vfs_ops.c
- Timestamp:
- 2017-03-21T19:20:30Z (8 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- e4e546b
- Parents:
- ebf1011
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/vfs/vfs_ops.c
rebf1011 rc990ee6 186 186 return rc; 187 187 } 188 188 189 async_wait_for(msg, &rc); 189 vfs_exchange_release(exch); 190 191 if (rc != EOK) 190 if (rc != EOK) { 191 vfs_exchange_release(exch); 192 192 return rc; 193 } 193 194 194 195 vfs_lookup_res_t res; … … 202 203 /* Add reference to the mounted root. */ 203 204 *root = vfs_node_get(&res); 204 assert(*root); 205 if (!*root) { 206 aid_t msg = async_send_1(exch, VFS_OUT_UNMOUNTED, 207 (sysarg_t) service_id, NULL); 208 async_forget(msg); 209 vfs_exchange_release(exch); 210 return ENOMEM; 211 } 205 212 213 vfs_exchange_release(exch); 214 206 215 return EOK; 207 216 } … … 541 550 vfs_node_put(base); 542 551 base = vfs_node_get(&base_lr); 552 if (!base) { 553 fibril_rwlock_write_unlock(&namespace_rwlock); 554 return ENOMEM; 555 } 543 556 old[shared] = '/'; 544 557 old += shared; … … 904 917 int rc = vfs_lookup_internal(parent->node, path, 905 918 walk_lookup_flags(flags), &lr); 906 907 919 if (rc != EOK) { 908 920 fibril_rwlock_read_unlock(&namespace_rwlock); … … 912 924 913 925 vfs_node_t *node = vfs_node_get(&lr); 926 if (!node) { 927 fibril_rwlock_read_unlock(&namespace_rwlock); 928 vfs_file_put(parent); 929 return ENOMEM; 930 } 914 931 915 932 vfs_file_t *file;
Note:
See TracChangeset
for help on using the changeset viewer.