Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/tester/devs/devman2.c

    r5d1b3aa r79ae36dd  
    4242#include <devman.h>
    4343#include <str.h>
     44#include <async.h>
    4445#include <vfs/vfs.h>
     46#include <vfs/vfs_sess.h>
    4547#include <sys/stat.h>
    4648#include <fcntl.h>
     
    6870                        continue;
    6971                }
    70                 int phone = fd_phone(fd);
     72                async_sess_t *sess = fd_session(EXCHANGE_SERIALIZE, fd);
    7173                close(fd);
    72                 if (phone < 0) {
    73                         TPRINTF("Failed opening phone: %s.\n", str_error(phone));
    74                         rc = phone;
     74                if (sess == NULL) {
     75                        TPRINTF("Failed opening phone: %s.\n", str_error(errno));
     76                        rc = errno;
    7577                        err_msg = "Failed opening file descriptor phone";
    7678                        continue;
    7779                }
    78                 async_hangup(phone);
     80                async_hangup(sess);
    7981                TPRINTF("Path `%s' okay.\n", path);
    8082                free(path);
     
    8385        }
    8486       
    85         if (path != NULL) {
     87        if (path != NULL)
    8688                free(path);
    87         }
    88 
     89       
    8990        return err_msg;
    9091}
Note: See TracChangeset for help on using the changeset viewer.