Write queue after connect windows

Should I remove the assert(0) from the default case?