Rsync read_int questions

jw schultz jw at
Sun Apr 27 10:27:06 EST 2003

On Sat, Apr 26, 2003 at 10:37:46AM -0700, Steve G wrote:
> Hello,
> I've been having all kinds of problems with rsync. I've
> tried versions 2.5.4-6. They all seem to have the same
> problems. Currently, I'm trying to use SystemImager, which
> uses rsync to transfer files. I get this:
> get_boel_binaries_tarball
> rsync -av
> /tmp/
> receiving file list ... ERROR: buffer overflow in
> recv_exclude_list
> rsync error: error allocating core memory buffers (code 22)
> at util.c(238)
> rsync: connection unexpectedly closed (28 bytes read so
> far)
> Looking at the code for recv_exclude_list, it seems real
> simple. However, I do see a couple of issues. Using 2.5.6
> source code, line 314 of exclude.c has an unsigned int, but
> its value is set by read_int - which is signed. Next, I
> follow
> read_int->readfd->read_unbuffered->read_timeout->read.
> Nowhere in this chain do a see a ntoh conversion. I traced
> through write_int and I don't see any hton conversions in
> the call chain either. How do you ensure an int is in the
> proper byte order across a network?

The *VAL macros in byteorder.h

> Also, should read_int & write_int use a union to enforce
> proper alignment?
> union int_align {
>    char b[4];
>    int32 foo;
> };
> All the errors I see seem to be related to read & write
> int.
> Thoughts? Am I barking up the wrong tree?

I think so.  There are too many people running this
successfully between x86 and PPC, sparc, Alpha, Mips, et al
for this to be likely.

Most likely you have misconfigured.  You don't say what OSs
you are on.

	J.W. Schultz            Pegasystems Technologies
	email address:		jw at

		Remember Cernan and Schmitt

More information about the rsync mailing list