Some bugfixes to make restart work properly
Work in converter