When exiting a room where one was host, server sends a REMOVE_TEAM for the local team. It appears that this loop would not break in that case. Add a log message and a break. (I've hit a frozen frontend twice now)
[patterns]
**.h = native
**.c = native
**.cpp = native
**.lua = native
**.txt = native
**.pas = native
**.inc = native
**.hs = native