![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
In our platform the sizeof of struct sockaddr_un is 1025 and the sizeof of SockAddr is 144. |
#3
| |||
| |||
|
|
-----Original Message----- From: Tom Lane [mailto:tgl (AT) sss (DOT) pgh.pa.us] Sent: mardi 10 mai 2005 18:46 To: vvanwynsberghe (AT) ccncsi (DOT) net Cc: pgsql-ports (AT) postgresql (DOT) org; pgsql-bugs (AT) postgresql (DOT) org Subject: Re: [BUGS] Bug Report with Postgres 7.4 on AIX 5.3 Vincent Vanwynsberghe <vvanwynsberghe (AT) ccncsi (DOT) net> writes: In our platform the sizeof of struct sockaddr_un is 1025 and the sizeof of SockAddr is 144. Doesn't AIX provide struct sockaddr_storage? That struct has to be at least as large as any of the other platform-specific sockaddr structs. regards, tom lane |
#4
| |||
| |||
|
|
The AIX 5.3 provide the structure sockaddr_storage : ... In Postgress this structure sockaddr_storage is filled with the structure sockaddr_un but the size of sockaddr_storage is less then the size of sockaddr_un and cause a memory overflow ! Do you have any idea how to find a workaround ? |
#5
| |||
| |||
|
|
The AIX 5.3 provide the structure sockaddr_storage : struct sockaddr_storage { ushort_t __ss_family; /* address family */ char __ss_pad1[_SS_PAD1SIZE]; /* pad up to alignment field */ #if defined(__64BIT__) || (defined(_ALL_SOURCE) && defined(_LONG_LONG)) int64_t __ss_align; /* field to force desired structure */ /* storage alignment */ #else int __ss_align[2]; #endif char __ss_pad2[_SS_PAD2SIZE]; /* pad to achieve desired size */ }; |
![]() |
| Thread Tools | |
| Display Modes | |
| |