Changeset 778d26d in mainline for uspace/lib


Ignore:
Timestamp:
2013-07-28T21:06:34Z (13 years ago)
Author:
Jiri Zarevucky <zarevucky.jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
9e9b168
Parents:
bf9dc4e2
Message:

Relativize rename().

Location:
uspace/lib
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/vfs/vfs.c

    rbf9dc4e2 r778d26d  
    730730        async_exch_t *exch = vfs_exchange_begin();
    731731       
    732         req = async_send_0(exch, VFS_IN_RENAME, NULL);
     732        req = async_send_1(exch, VFS_IN_RENAME, -1, NULL);
    733733        rc = async_data_write_start(exch, olda, olda_size);
    734734        if (rc != EOK) {
  • uspace/lib/c/include/ipc/vfs.h

    rbf9dc4e2 r778d26d  
    126126
    127127/**
     128 * Lookup will not cross any mount points.
     129 * If the lookup would have to cross a mount point, it returns EXDEV instead.
     130 */
     131#define L_DISABLE_MOUNTS        4
     132
     133/**
    128134 * Lookup will succeed only if the object is a mount point. The flag is mutually
    129135 * exclusive with L_FILE and L_ROOT.
  • uspace/lib/fs/libfs.c

    rbf9dc4e2 r778d26d  
    632632       
    633633        if (cur->mp_data.mp_active) {
     634                if (lflag & L_DISABLE_MOUNTS) {
     635                        async_answer_0(rid, EXDEV);
     636                        LOG_EXIT(EXDEV);
     637                        goto out;
     638                }
     639               
    634640                async_exch_t *exch = async_exchange_begin(cur->mp_data.sess);
    635641                async_forward_slow(rid, exch, VFS_OUT_LOOKUP, next, last - next,
     
    692698                if ((tmp) && (tmp->mp_data.mp_active) &&
    693699                    (!(lflag & L_MP) || (next < last))) {
     700                       
     701                        if (lflag & L_DISABLE_MOUNTS) {
     702                                async_answer_0(rid, EXDEV);
     703                                LOG_EXIT(EXDEV);
     704                                goto out;
     705                        }
     706                       
    694707                        async_exch_t *exch = async_exchange_begin(tmp->mp_data.sess);
    695708                        async_forward_slow(rid, exch, VFS_OUT_LOOKUP, next,
Note: See TracChangeset for help on using the changeset viewer.