Check that GstSdpMessage is not NULL before using it

Change-Id: I63a8e83dfefc037c466c4a356f0865a84f6f0a6f