Reenable call to switch_protocol() on protocol version mismatches
Reenable call to switch_protocol() on protocol version mismatches

This partially reverts b19acbc. This commit broke the fallback
to the old protocol as it added a check for c->peer_msg != NULL
before calling switch_protocol(), but mismatch between local
and remote protocol versions is detected before c->peer_msg is
allocated, so:
    if (c->peer_msg != NULL && c->link_hdr.major_version != 1) {
         SPICE_DEBUG("%s: error, switching to protocol 1 (spice 0.4)",
c->name);
         spice_channel_switch_protocol(channel, 1);
         return TRUE;
    }
will never get triggered when c->peer_hdr.major_version !=
c->link_hdr.major_version

The crash described in b19acbc occurred when calling
spice_channel_recv_link_msg() in spice_channel_coroutine()
after a call to spice_channel_recv_link_hdr() failed and did
not set c->peer_msg.

This commit removes the c>peer_msg check done before calling
spice_channel_switch_protocol() so that it gets called when needed,
but makes sure that we return FALSE to indicate that an error happened
and that we need to reconnect. This way we won't try to call
spice_channel_recv_link_msg() when c->peer_msg is NULL.

guodong/spice-gtk,Fantu/spice-gtk,elmarco/spice-gtk,freedesktop-unofficial-mirror/spice__spice-gtk,fgouget/spice-gtk,flexVDI/spice-gtk,Fantu/spice-gtk,guodong/spice-gtk,freedesktop-unofficial-mirror/spice__spice-gtk,elmarco/spice-gtk,Fantu/spice-gtk,freedesktop-unofficial-mirror/spice__spice-gtk,fgouget/spice-gtk,Fantu/spice-gtk,elmarco/spice-gtk,guodong/spice-gtk,SPICE/spice-gtk,elmarco/spice-gtk,SPICE/spice-gtk,SPICE/spice-gtk,freedesktop-unofficial-mirror/spice__spice-gtk,flexVDI/spice-gtk,SPICE/spice-gtk,guodong/spice-gtk,fgouget/spice-gtk