summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Brewer <ben.brewer@codethink.co.uk>2014-05-29 16:09:15 (GMT)
committerBen Brewer <ben.brewer@codethink.co.uk>2014-06-02 10:03:00 (GMT)
commit8e85b1b2001f8d747a41e41f616d20d84bf65acc (patch)
treefa6f8e12575ce4236e9d6d309f01ef379169f824
parent120e5ad8b73585df0ef0c59164e5fa2f545515f3 (diff)
downloadtbdiff-8e85b1b2001f8d747a41e41f616d20d84bf65acc.tar.gz
style: Cleanup the names of the tbd read/write wrappers
-rw-r--r--tbdiff/tbdiff-apply.c92
-rw-r--r--tbdiff/tbdiff-create.c24
-rw-r--r--tbdiff/tbdiff-io.c32
-rw-r--r--tbdiff/tbdiff-io.h32
4 files changed, 90 insertions, 90 deletions
diff --git a/tbdiff/tbdiff-apply.c b/tbdiff/tbdiff-apply.c
index 07a9961..754df5e 100644
--- a/tbdiff/tbdiff-apply.c
+++ b/tbdiff/tbdiff-apply.c
@@ -46,7 +46,7 @@ char*
tbd_apply_fread_string(FILE *stream)
{
uint16_t dlen;
- if(tbd_read_uint16_t(&dlen, stream) != 1)
+ if(tbd_read_uint16(&dlen, stream) != 1)
return NULL;
char dname[dlen + 1];
if(fread(dname, 1, dlen, stream) != dlen)
@@ -99,7 +99,7 @@ tbd_apply_identify(FILE *stream)
if(cmd != TBD_CMD_IDENTIFY)
return TBD_ERROR(TBD_ERROR_INVALID_PARAMETER);
uint16_t nlen;
- if(tbd_read_uint16_t(&nlen, stream) != 1)
+ if(tbd_read_uint16(&nlen, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
if(strlen(TB_DIFF_PROTOCOL_ID) != nlen)
return TBD_ERROR(TBD_ERROR_INVALID_PARAMETER);
@@ -115,7 +115,7 @@ static int
tbd_apply_cmd_dir_create(FILE *stream)
{
uint16_t dlen;
- if(tbd_read_uint16_t(&dlen, stream) != 1)
+ if(tbd_read_uint16(&dlen, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char dname[dlen + 1];
if(fread(dname, 1, dlen, stream) != dlen)
@@ -126,19 +126,19 @@ tbd_apply_cmd_dir_create(FILE *stream)
return TBD_ERROR(TBD_ERROR_INVALID_PARAMETER);
time_t mtime;
- if(tbd_read_time_t(&mtime, stream) != 1)
+ if(tbd_read_time(&mtime, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
uid_t uid;
- if(tbd_read_uid_t(&uid, stream) != 1)
+ if(tbd_read_uid(&uid, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
gid_t gid;
- if(tbd_read_gid_t(&gid, stream) != 1)
+ if(tbd_read_gid(&gid, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
mode_t mode;
- if(tbd_read_mode_t(&mode, stream) != 1)
+ if(tbd_read_mode(&mode, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
if(mkdir(dname, (mode_t)mode) != 0)
@@ -159,7 +159,7 @@ tbd_apply_cmd_dir_enter(FILE *stream,
uintptr_t *depth)
{
uint16_t dlen;
- if(tbd_read_uint16_t(&dlen, stream) != 1)
+ if(tbd_read_uint16(&dlen, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char dname[dlen + 1];
if(fread(dname, 1, dlen, stream) != dlen)
@@ -183,7 +183,7 @@ tbd_apply_cmd_dir_leave(FILE *stream,
int err = TBD_ERROR_SUCCESS;
struct utimbuf time;
- if (tbd_read_time_t(&(time.modtime), stream) != 1) {
+ if (tbd_read_time(&(time.modtime), stream) != 1) {
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
}
time.actime = time.modtime;/* not sure what the best atime to use is */
@@ -214,7 +214,7 @@ static int
tbd_apply_cmd_file_create(FILE *stream)
{
uint16_t flen;
- if(tbd_read_uint16_t(&flen, stream) != 1)
+ if(tbd_read_uint16(&flen, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char fname[flen + 1];
if(fread(fname, 1, flen, stream) != flen)
@@ -229,11 +229,11 @@ tbd_apply_cmd_file_create(FILE *stream)
gid_t gid;
uint32_t fsize;
- if(tbd_read_time_t (&mtime, stream) != 1 ||
- tbd_read_uint32_t(&mode , stream) != 1 ||
- tbd_read_uid_t (&uid , stream) != 1 ||
- tbd_read_gid_t (&gid , stream) != 1 ||
- tbd_read_uint32_t(&fsize, stream) != 1)
+ if(tbd_read_time (&mtime, stream) != 1 ||
+ tbd_read_uint32(&mode , stream) != 1 ||
+ tbd_read_uid (&uid , stream) != 1 ||
+ tbd_read_gid (&gid , stream) != 1 ||
+ tbd_read_uint32(&fsize, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
fprintf(stderr, "cmd_file_create %s:%"PRId32"\n", fname, fsize);
@@ -287,7 +287,7 @@ tbd_apply_cmd_file_delta(FILE *stream)
uint16_t flen;
int error;
- if(tbd_read_uint16_t(&flen, stream) != 1)
+ if(tbd_read_uint16(&flen, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char fname[flen + 1];
if(fread(fname, 1, flen, stream) != flen)
@@ -301,11 +301,11 @@ tbd_apply_cmd_file_delta(FILE *stream)
return TBD_ERROR(TBD_ERROR_INVALID_PARAMETER);
/* Reading metadata */
- if(tbd_read_uint16_t(&mdata_mask, stream) != 1 ||
- tbd_read_time_t (&mtime , stream) != 1 ||
- tbd_read_uid_t (&uid , stream) != 1 ||
- tbd_read_gid_t (&gid , stream) != 1 ||
- tbd_read_uint32_t(&mode , stream) != 1)
+ if(tbd_read_uint16(&mdata_mask, stream) != 1 ||
+ tbd_read_time (&mtime , stream) != 1 ||
+ tbd_read_uid (&uid , stream) != 1 ||
+ tbd_read_gid (&gid , stream) != 1 ||
+ tbd_read_uint32(&mode , stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
FILE *op = fopen(fname, "rb");
@@ -322,11 +322,11 @@ tbd_apply_cmd_file_delta(FILE *stream)
}
uint32_t dstart, dend;
- if(tbd_read_uint32_t(&dstart, stream) != 1) {
+ if(tbd_read_uint32(&dstart, stream) != 1) {
error = TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
goto tbd_apply_cmd_file_delta_error;
}
- if(tbd_read_uint32_t(&dend, stream) != 1) {
+ if(tbd_read_uint32(&dend, stream) != 1) {
error = TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
goto tbd_apply_cmd_file_delta_error;
}
@@ -347,7 +347,7 @@ tbd_apply_cmd_file_delta(FILE *stream)
}
uint32_t fsize;
- if(tbd_read_uint32_t(&fsize, stream) != 1) {
+ if(tbd_read_uint32(&fsize, stream) != 1) {
error = TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
goto tbd_apply_cmd_file_delta_error;
}
@@ -478,7 +478,7 @@ static int
tbd_apply_cmd_entity_delete(FILE *stream)
{
uint16_t elen;
- if(tbd_read_uint16_t(&elen, stream) != 1)
+ if(tbd_read_uint16(&elen, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char ename[elen + 1];
if(fread(ename, 1, elen, stream) != elen)
@@ -500,13 +500,13 @@ tbd_apply_cmd_symlink_create(FILE *stream)
uid_t uid;
gid_t gid;
- if(tbd_read_time_t(&mtime, stream) != 1 ||
- tbd_read_uid_t(&uid , stream) != 1 ||
- tbd_read_gid_t(&gid , stream) != 1)
+ if(tbd_read_time(&mtime, stream) != 1 ||
+ tbd_read_uid(&uid , stream) != 1 ||
+ tbd_read_gid(&gid , stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
/* Reading link file name */
- if(tbd_read_uint16_t(&len, stream) != 1)
+ if(tbd_read_uint16(&len, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char linkname[len + 1];
@@ -515,7 +515,7 @@ tbd_apply_cmd_symlink_create(FILE *stream)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
/* Reading target path */
- if(tbd_read_uint16_t(&len, stream) != 1)
+ if(tbd_read_uint16(&len, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char linkpath[len+1];
linkpath[len] = '\0';
@@ -550,11 +550,11 @@ tbd_apply_cmd_special_create(FILE *stream)
uint32_t dev;
if(name == NULL ||
- tbd_read_time_t (&mtime, stream) != 1 ||
- tbd_read_mode_t (&mode , stream) != 1 ||
- tbd_read_uid_t (&uid , stream) != 1 ||
- tbd_read_gid_t (&gid , stream) != 1 ||
- tbd_read_uint32_t(&dev , stream) != 1) {
+ tbd_read_time (&mtime, stream) != 1 ||
+ tbd_read_mode (&mode , stream) != 1 ||
+ tbd_read_uid (&uid , stream) != 1 ||
+ tbd_read_gid (&gid , stream) != 1 ||
+ tbd_read_uint32(&dev , stream) != 1) {
free(name);
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
}
@@ -585,11 +585,11 @@ tbd_apply_cmd_dir_delta(FILE *stream)
gid_t gid;
mode_t mode;
- if(tbd_read_uint16_t(&metadata_mask, stream) != 1 ||
- tbd_read_time_t (&mtime , stream) != 1 ||
- tbd_read_uid_t (&uid , stream) != 1 ||
- tbd_read_gid_t (&gid , stream) != 1 ||
- tbd_read_uint32_t(&mode , stream) != 1)
+ if(tbd_read_uint16(&metadata_mask, stream) != 1 ||
+ tbd_read_time (&mtime , stream) != 1 ||
+ tbd_read_uid (&uid , stream) != 1 ||
+ tbd_read_gid (&gid , stream) != 1 ||
+ tbd_read_uint32(&mode , stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char *dname = tbd_apply_fread_string(stream);
@@ -620,11 +620,11 @@ tbd_apply_cmd_file_mdata_update(FILE *stream)
gid_t gid;
mode_t mode;
- if(tbd_read_uint16_t(&metadata_mask, stream) != 1 ||
- tbd_read_time_t (&mtime , stream) != 1 ||
- tbd_read_uid_t (&uid , stream) != 1 ||
- tbd_read_gid_t (&gid , stream) != 1 ||
- tbd_read_uint32_t(&mode , stream) != 1)
+ if(tbd_read_uint16(&metadata_mask, stream) != 1 ||
+ tbd_read_time (&mtime , stream) != 1 ||
+ tbd_read_uid (&uid , stream) != 1 ||
+ tbd_read_gid (&gid , stream) != 1 ||
+ tbd_read_uint32(&mode , stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
char *dname = tbd_apply_fread_string(stream);
@@ -665,7 +665,7 @@ tbd_apply_cmd_xattrs_update(FILE *stream)
}
/* read how many attributes to process */
- if (tbd_read_uint32_t(&count, stream) != 1) {
+ if (tbd_read_uint32(&count, stream) != 1) {
err = TBD_ERROR(TBD_ERROR_UNABLE_TO_READ_STREAM);
goto cleanup;
}
diff --git a/tbdiff/tbdiff-create.c b/tbdiff/tbdiff-create.c
index 873f6ee..c8a71ff 100644
--- a/tbdiff/tbdiff-create.c
+++ b/tbdiff/tbdiff-create.c
@@ -46,7 +46,7 @@ tbd_create_fwrite_string(FILE *stream,
const char *string)
{
uint16_t slen = strlen(string);
- if((tbd_write_uint16_t(slen, stream) != 1)
+ if((tbd_write_uint16(slen, stream) != 1)
|| (fwrite(string, 1, slen, stream) != slen))
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
return 0;
@@ -71,7 +71,7 @@ static int
tbd_create_fwrite_mdata_mask(FILE *stream,
uint16_t mask)
{
- if(tbd_write_uint16_t(mask, stream) != 1)
+ if(tbd_write_uint16(mask, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
return 0;
}
@@ -80,7 +80,7 @@ static int
tbd_create_fwrite_mtime(FILE *stream,
time_t mtime)
{
- if(tbd_write_time_t(mtime, stream) != 1)
+ if(tbd_write_time(mtime, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
return 0;
}
@@ -89,7 +89,7 @@ static int
tbd_create_fwrite_mode(FILE *stream,
mode_t mode)
{
- if(tbd_write_mode_t(mode, stream) != 1)
+ if(tbd_write_mode(mode, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
return 0;
}
@@ -98,7 +98,7 @@ static int
tbd_create_fwrite_gid(FILE *stream,
gid_t gid)
{
- if(tbd_write_gid_t(gid, stream) != 1)
+ if(tbd_write_gid(gid, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
return 0;
}
@@ -107,7 +107,7 @@ static int
tbd_create_fwrite_uid(FILE *stream,
uid_t uid)
{
- if(tbd_write_uid_t(uid, stream) != 1)
+ if(tbd_write_uid(uid, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
return 0;
}
@@ -116,7 +116,7 @@ static int
tbd_create_fwrite_dev(FILE *stream,
uint32_t dev)
{
- if(tbd_write_uint32_t(dev, stream) != 1)
+ if(tbd_write_uint32(dev, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
return 0;
}
@@ -199,7 +199,7 @@ tbd_create_cmd_fwrite_xattrs(FILE *stream, tbd_stat_t *f)
goto cleanup_names;
}
- if (tbd_write_uint32_t(count, stream) != 1) {
+ if (tbd_write_uint32(count, stream) != 1) {
err = TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
goto cleanup_names;
}
@@ -229,7 +229,7 @@ tbd_create_cmd_file_create(FILE *stream,
return err;
uint32_t size = f->size;
- if(tbd_write_uint32_t(size, stream) != 1)
+ if(tbd_write_uint32(size, stream) != 1)
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
FILE *fp = tbd_stat_fopen(f, "rb");
@@ -410,9 +410,9 @@ tbd_create_cmd_file_delta(FILE *stream,
fclose(fpb);
return err;
}
- if((tbd_write_uint32_t(start, stream) != 1) ||
- (tbd_write_uint32_t(end, stream) != 1) ||
- (tbd_write_uint32_t(size, stream) != 1)) {
+ if((tbd_write_uint32(start, stream) != 1) ||
+ (tbd_write_uint32(end, stream) != 1) ||
+ (tbd_write_uint32(size, stream) != 1)) {
fclose(fpb);
return TBD_ERROR(TBD_ERROR_UNABLE_TO_WRITE_STREAM);
}
diff --git a/tbdiff/tbdiff-io.c b/tbdiff/tbdiff-io.c
index db3b437..d6be7c9 100644
--- a/tbdiff/tbdiff-io.c
+++ b/tbdiff/tbdiff-io.c
@@ -52,69 +52,69 @@ static inline void endianswap(void* value, size_t size)
#define ENDIANSWAP(v)
#endif
-size_t tbd_write_uint16_t(uint16_t value, FILE *stream) {
+size_t tbd_write_uint16(uint16_t value, FILE *stream) {
ENDIANSWAP(&value);
return fwrite(&value, sizeof(value), 1, stream);
}
-size_t tbd_write_uint32_t(uint32_t value, FILE *stream) {
+size_t tbd_write_uint32(uint32_t value, FILE *stream) {
ENDIANSWAP(&value);
return fwrite(&value, sizeof(value), 1, stream);
}
-size_t tbd_write_uint64_t(uint64_t value, FILE *stream) {
+size_t tbd_write_uint64(uint64_t value, FILE *stream) {
ENDIANSWAP(&value);
return fwrite(&value, sizeof(value), 1, stream);
}
-size_t tbd_write_time_t(time_t value, FILE *stream) {
+size_t tbd_write_time(time_t value, FILE *stream) {
uint64_t realv = value;
ENDIANSWAP(&realv);
return fwrite(&realv, sizeof(realv), 1, stream);
}
-size_t tbd_write_mode_t(mode_t value, FILE *stream) {
+size_t tbd_write_mode(mode_t value, FILE *stream) {
ENDIANSWAP(&value);
return fwrite(&value, sizeof(value), 1, stream);
}
-size_t tbd_write_uid_t(uid_t value, FILE *stream) {
+size_t tbd_write_uid(uid_t value, FILE *stream) {
ENDIANSWAP(&value);
return fwrite(&value, sizeof(value), 1, stream);
}
-size_t tbd_write_gid_t(gid_t value, FILE *stream) {
+size_t tbd_write_gid(gid_t value, FILE *stream) {
ENDIANSWAP(&value);
return fwrite(&value, sizeof(value), 1, stream);
}
-size_t tbd_write_size_t(size_t value, FILE *stream) {
+size_t tbd_write_size(size_t value, FILE *stream) {
ENDIANSWAP(&value);
return fwrite(&value, sizeof(value), 1, stream);
}
-size_t tbd_read_uint16_t(uint16_t *value, FILE *stream) {
+size_t tbd_read_uint16(uint16_t *value, FILE *stream) {
assert(value != NULL);
size_t rval = fread(value, sizeof(*value), 1, stream);
ENDIANSWAP(value);
return rval;
}
-size_t tbd_read_uint32_t(uint32_t *value, FILE *stream) {
+size_t tbd_read_uint32(uint32_t *value, FILE *stream) {
assert(value != NULL);
size_t rval = fread(value, sizeof(*value), 1, stream);
ENDIANSWAP(value);
return rval;
}
-size_t tbd_read_uint64_t(uint64_t *value, FILE *stream) {
+size_t tbd_read_uint64(uint64_t *value, FILE *stream) {
assert(value != NULL);
size_t rval = fread(value, sizeof(*value), 1, stream);
ENDIANSWAP(value);
return rval;
}
-size_t tbd_read_time_t(time_t *value, FILE *stream) {
+size_t tbd_read_time(time_t *value, FILE *stream) {
assert(value != NULL);
uint64_t realv;
size_t rval = fread(&realv, sizeof(realv), 1, stream);
@@ -123,28 +123,28 @@ size_t tbd_read_time_t(time_t *value, FILE *stream) {
return rval;
}
-size_t tbd_read_mode_t(mode_t *value, FILE *stream) {
+size_t tbd_read_mode(mode_t *value, FILE *stream) {
assert(value != NULL);
size_t rval = fread(value, sizeof(*value), 1, stream);
ENDIANSWAP(value);
return rval;
}
-size_t tbd_read_uid_t(uid_t *value, FILE *stream) {
+size_t tbd_read_uid(uid_t *value, FILE *stream) {
assert(value != NULL);
size_t rval = fread(value, sizeof(*value), 1, stream);
ENDIANSWAP(value);
return rval;
}
-size_t tbd_read_gid_t(gid_t *value, FILE *stream) {
+size_t tbd_read_gid(gid_t *value, FILE *stream) {
assert(value != NULL);
size_t rval = fread(value, sizeof(*value), 1, stream);
ENDIANSWAP(value);
return rval;
}
-size_t tbd_read_size_t(size_t *value, FILE *stream) {
+size_t tbd_read_size(size_t *value, FILE *stream) {
assert(value != NULL);
size_t rval = fread(value, sizeof(*value), 1, stream);
ENDIANSWAP(value);
diff --git a/tbdiff/tbdiff-io.h b/tbdiff/tbdiff-io.h
index 0e2e7e9..16601fb 100644
--- a/tbdiff/tbdiff-io.h
+++ b/tbdiff/tbdiff-io.h
@@ -28,22 +28,22 @@
#include <tbdiff/tbdiff-stat.h>
-extern size_t tbd_write_uint16_t(uint16_t value, FILE* stream);
-extern size_t tbd_write_uint32_t(uint32_t value, FILE* stream);
-extern size_t tbd_write_uint64_t(uint64_t value, FILE* stream);
-extern size_t tbd_write_time_t(time_t value, FILE* stream);
-extern size_t tbd_write_mode_t(mode_t value, FILE* stream);
-extern size_t tbd_write_uid_t(uid_t value, FILE* stream);
-extern size_t tbd_write_gid_t(gid_t value, FILE* stream);
-extern size_t tbd_write_size_t(size_t value, FILE* stream);
+extern size_t tbd_write_uint16(uint16_t value, FILE* stream);
+extern size_t tbd_write_uint32(uint32_t value, FILE* stream);
+extern size_t tbd_write_uint64(uint64_t value, FILE* stream);
+extern size_t tbd_write_time(time_t value, FILE* stream);
+extern size_t tbd_write_mode(mode_t value, FILE* stream);
+extern size_t tbd_write_uid(uid_t value, FILE* stream);
+extern size_t tbd_write_gid(gid_t value, FILE* stream);
+extern size_t tbd_write_size(size_t value, FILE* stream);
-extern size_t tbd_read_uint16_t(uint16_t *value, FILE* stream);
-extern size_t tbd_read_uint32_t(uint32_t *value, FILE* stream);
-extern size_t tbd_read_uint64_t(uint64_t *value, FILE* stream);
-extern size_t tbd_read_time_t(time_t *value, FILE* stream);
-extern size_t tbd_read_mode_t(mode_t *value, FILE* stream);
-extern size_t tbd_read_uid_t(uid_t *value, FILE* stream);
-extern size_t tbd_read_gid_t(gid_t *value, FILE* stream);
-extern size_t tbd_read_size_t(size_t *value, FILE* stream);
+extern size_t tbd_read_uint16(uint16_t *value, FILE* stream);
+extern size_t tbd_read_uint32(uint32_t *value, FILE* stream);
+extern size_t tbd_read_uint64(uint64_t *value, FILE* stream);
+extern size_t tbd_read_time(time_t *value, FILE* stream);
+extern size_t tbd_read_mode(mode_t *value, FILE* stream);
+extern size_t tbd_read_uid(uid_t *value, FILE* stream);
+extern size_t tbd_read_gid(gid_t *value, FILE* stream);
+extern size_t tbd_read_size(size_t *value, FILE* stream);
#endif /* !__TBDIFF_IO_H__ */