rem: return EBADF;
add: return FS_EBADF;
context: parse_path_fd(bool kernel, int fd, char **pstart, int eatsymlink, vnode **vnp){    vnode           *bvn;    ofile           *f;    ioctx           *io;    char            *path;    path = *pstart;    if (path && (*path == '/')) {        do            path++;        while (*path == '/');        bvn = rootvn;        inc_vnode(bvn);    } else        if (fd >= 0) {            f = get_fd(kernel, fd, FD_ALL);            if (!f)                return EBADF;            bvn = f->vn;            inc_vnode(bvn);            put_fd(f);        } else {            io = get_cur_ioctx();            LOCK(io->lock);            bvn = io->cwd;            inc_vnode(bvn);            UNLOCK(io->lock);        }    return parse_path(bvn, pstart, path, eatsymlink, vnp);}