• David Goodell's avatar
    [svn-r9716] tt#1599: eliminate MPIDI_CH3_PktGeneric_t · f868be22
    David Goodell authored
    Without this change we are vulnerable to a nasty bit of compiler
    behavior.  MPIDI_CH3_PktGeneric_t sometimes included padding between the
    "kind" and "pktptrs" fields.  Then whole-structure assignments using the
    generic packet (e.g., ch3_istartmsg.c:96) of buffers that are actually
    MPIDI_CH3_Pkt_t unions under the hood will can fail to copy key parts of
    the MPIDI_CH3_Pkt_t.
    This specifically manifested itself for #1599 by transmitting garbage
    "source_win_handle" values in a LOCK_GRANTED packet, which in turn
    caused segfaults.
    Removing this second type and directly using the actual packet union
    eliminates this source of bugs.  The minor downside is that the
    mpidpkt.h header becomes more tightly integrated into the rest of the
    Reviewed by buntinas@.