Bug 1051521, Fix assertion when OnCloseChannel loses the race with OnChannelError, r=bsmedberg.