]> git.ipfire.org Git - thirdparty/postgresql.git/commit
MemSet() must not cast its pointer argument to int32* until after it has
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 18 Jul 2005 15:54:30 +0000 (15:54 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 18 Jul 2005 15:54:30 +0000 (15:54 +0000)
commit5394771580977364b1994e0a2fb302c9ceb00212
treeb7dd6894eab31b132d47ee53e47de7cb7c604f0d
parent509741d3d502c354d00ebffe046e643348ef4dd4
MemSet() must not cast its pointer argument to int32* until after it has
checked that the pointer is actually word-aligned.  Casting a non-aligned
pointer to int32* is technically illegal per the C spec, and some recent
versions of gcc actually generate bad code for the memset() when given
such a pointer.  Per report from Andrew Morrow.
src/include/c.h