Previous: xmap_compact, Up: Internal Functions
xmap_process
#include <bpipe/bpipe.h>static int xmap_process( void *udata, size_t dst, size_t src, size_t size );
void *udata
- copy routine specific data
size_t dst
- destination of chunk
size_t src
- source of chunk
size_t size
- size of chunk in bytes
This is a callback routine invoked by bpipe_datatype_copy
.
Instead of copying, it stores the source, destination, and length in
a file global linked list, which will be compacted by
xmap_compact
after all data packet fields have been
processed.
It returns zero upon success, non-zero upon failure (out of memoryb).
It sets bpipe_errno
to BPENOMEM
upon failure.