Fmove
, Fmove32
-move fielded buffer to destination
#include <stdio.h>
#include "fml.h"
int
Fmove(char *dest, FBFR *src)
#include "fml32.h"
int
Fmove32(char *dest, FBFR32 *src)
Fmove
() should be used when copying from a fielded buffer to any type of buffer. dest and src are pointers to the destination buffer and the source fielded buffers respectively.
The difference between Fmove
() and Fcpy
(3) is that Fcpy
(3) expects the destination to be a fielded buffer and thus can make sure it is of sufficient size to accommodate the data from the source buffer. Fmove
() makes no such check, blindly moving Fsizeof
(3) bytes of data from the source fielded buffer to the target buffer. The destination buffer must be aligned on a short boundary.
Fmove32
is used with 32-bit FML.
This function returns \-1 on error and sets Ferror
to indicate the error condition.
Under the following conditions, Fmove
() fails and sets Ferror
to:
[FALIGNERR]
[FNOTFLD]
Finit
().
Fintro
(3), Fcpy
(3), Fsizeof
(3)