Subject: Zoularis questions
To: None <tech-pkg@netbsd.org>
From: Bill Studenmund <wrstuden@netbsd.org>
List: tech-pkg
Date: 09/20/2001 12:35:41
  This message is in MIME format.  The first part should be readable text,
  while the remaining parts are likely unreadable without MIME-aware tools.
  Send mail to mime@docserver.cac.washington.edu for more info.

--0-1447576425-1001014541=:348
Content-Type: TEXT/PLAIN; charset=US-ASCII

I'm trying to get zoularis working on Solaris 7. It seems that some of the
Solaris 8 changes broke it, and I'd like advice on how to fix it. I'm
attaching patches which work for me, but which I don't think will work for
everyone else.

The big problem is that different systems Zoularis wants to support use
different sized fields for indicating socket address family. In 43BSD, it
was a short (2 bytes). Sol 7 follows in the 43BSD vein. 44BSD systems
changed the field length to one byte, and added an address length field,
also one byte. Thus everything other than the family or length/family
stayed the same.

The patches I'm including try to make sure we do the right thing and not
make sa_family_t the wrong size. I also change sockaddr_storage so that
any library routines which use it will be able to hand off the rignt
thing to other programs.

Thoughts on what to do other than make it depend on Solaris 7?

Take care,

Bill

--0-1447576425-1001014541=:348
Content-Type: TEXT/PLAIN; charset=US-ASCII; name=cvsdiff
Content-Transfer-Encoding: BASE64
Content-ID: <Pine.NEB.4.33.0109201235410.348@vespasia.home-net.internetconnect.net>
Content-Description: patches
Content-Disposition: attachment; filename=cvsdiff

SW5kZXg6IGJzZC9pbmNsdWRlL25ldGluZXQvaW4uaC5zZWQNCj09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT0NClJDUyBmaWxlOiAvY3Zzcm9vdC9vdGhlcnNyYy96
b3VsYXJpcy9ic2QvaW5jbHVkZS9uZXRpbmV0L2luLmguc2VkLHYNCnJldHJp
ZXZpbmcgcmV2aXNpb24gMS40DQpkaWZmIC11IC1yMS40IGluLmguc2VkDQot
LS0gaW4uaC5zZWQJMjAwMS8wNy8wNCAyMDo1MjozOAkxLjQNCisrKyBpbi5o
LnNlZAkyMDAxLzA5LzIwIDIxOjM3OjM2DQ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