Correct fix for unaligned memcpy - malloc'ed memory incremented by sizeof(struct...
authorJeremy Allison <jra@samba.org>
Tue, 18 Sep 2001 06:41:29 +0000 (06:41 +0000)
committerJeremy Allison <jra@samba.org>
Tue, 18 Sep 2001 06:41:29 +0000 (06:41 +0000)
commit5bc82e443b2da885aa0a504906789c006b3cf17a
tree6440822892634cb6e10c373eeea833066ab37a96
parent36a6611da2820da3635a8158dd26f41732b5b4fd
Correct fix for unaligned memcpy - malloc'ed memory incremented by sizeof(struct locking_data)
was not forced to be 8 byte aligned. Use union to force it to be correctly aligned
for memcpy and use void *, to tell compiler not to optimize aligned copy (this last fix
suggested by Trond @ RedHat). The first fix should be sufficient, but this provides a
"belt and braces" fix.
Jeremy.
(This used to be commit 22c5915bb466529ac1bcb5c2574888b360a9775b)
source3/include/smb.h
source3/locking/locking.c