Add some protection code such that the new example programs don't crash anymore.
Add some protection code such that the new example programs don't crash
anymore.

ossy-szeged/sctp-refimpl,ossy-szeged/sctp-refimpl,ossy-szeged/sctp-refimpl,ossy-szeged/sctp-refimpl,ossy-szeged/sctp-refimpl,ossy-szeged/sctp-refimpl,ossy-szeged/sctp-refimpl,ossy-szeged/sctp-refimpl,ossy-szeged/sctp-refimpl