1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-11 05:18:09 +03:00

Modified auto alignment of ud[] struct on stack to be declared as an

array of pointers. This should cause alignment on a correct boundary..
Spotted by Darren Reed <darrenr@telnetmedia.com>.
Jeremy.
(This used to be commit 91f4d06753)
This commit is contained in:
Jeremy Allison 2000-01-28 23:47:31 +00:00
parent 451dcb3351
commit 40122f6e32
2 changed files with 4 additions and 4 deletions

View File

@ -203,8 +203,8 @@ void make_wins_proxy_name_query_request( struct subnet_record *subrec,
struct packet_struct *incoming_packet,
struct nmb_name *question_name)
{
char ud[sizeof(struct userdata_struct) + sizeof(struct subrec *) +
sizeof(struct packet_struct *)];
long *ud[(sizeof(struct userdata_struct) + sizeof(struct subrec *) +
sizeof(struct packet_struct *))/sizeof(long *) + 1];
struct userdata_struct *userdata = (struct userdata_struct *)ud;
memset(ud, '\0', sizeof(ud));

View File

@ -838,7 +838,7 @@ is one of our (WINS server) names. Denying registration.\n", nmb_namestr(questio
if( namerec != NULL )
{
char ud[sizeof(struct userdata_struct) + sizeof(struct packet_struct *)];
long *ud[(sizeof(struct userdata_struct) + sizeof(struct packet_struct *))/sizeof(long *) + 1];
struct userdata_struct *userdata = (struct userdata_struct *)ud;
/*
@ -1146,7 +1146,7 @@ is one of our (WINS server) names. Denying registration.\n", nmb_namestr(questio
if(namerec != NULL)
{
char ud[sizeof(struct userdata_struct) + sizeof(struct packet_struct *)];
long *ud[(sizeof(struct userdata_struct) + sizeof(struct packet_struct *))/sizeof(long *) + 1];
struct userdata_struct *userdata = (struct userdata_struct *)ud;
/*