#include <fcntl.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <stdlib.h>
#include <misc/debug.h>
#include <misc/generic_types.h>
#include <core/tx.h>
#include <core/config.h>
#include <core/koa.h>
#include <core/buffer.h>
#include <core/stats.h>
#include <libc/syscalls.h>
#include <core/txdesc.h>
#include <xcalls/xcalls.h>
Go to the source code of this file.
Classes | |
struct | x_read_pipe_commit_undo_args_s |
Typedefs | |
typedef x_read_pipe_commit_undo_args_s | x_read_pipe_commit_undo_args_t |
Functions | |
ssize_t XCALL_DEF() | x_read_pipe (int fd, void *buf, size_t nbyte, int *result) |
Reads from a pipe. |
Definition in file x_read_pipe.c.
ssize_t XCALL_DEF() x_read_pipe | ( | int | fd, | |
void * | buf, | |||
size_t | nbyte, | |||
int * | result | |||
) |
Reads from a pipe.
The xCall buffers any read data so that in case of transaction abort read data are not consumed but stay present for the next pipe read.
Execution : in-place
Asynchronous failures : commit, abort
[in] | fd | The file descriptor of the pipe's read end. |
[in] | buf | The buffer where to store read data. |
[in] | nbyte | The number of bytes to read. |
[out] | result | Where to store asynchronous failures. |
Definition at line 257 of file x_read_pipe.c.
References TXC_INTERNALERROR, txc_tx_get_txd(), and txc_tx_get_xactstate().