I think your theory is correct, the repacked storage building needed 1 empty place in your existing inventory to repack to . From what I understand this wasn't available, as it had no spare inventory slot, it went ..... well who knows ???. But why that would break your Civ I don't know. Also...