Check if GetBuffer actually returned a buffer, prevents unexpected crashes