forked from qt-creator/qt-creator
The infinite recursion occurs because we call QFileInfo::exists() even if no change/fix is done, if a file in a resource if actually missing. If fileName != fixedPath the ":" prefix has been replaced by an absolute path and a new call to ::create will early reject. Typically the directories do not match, so nothing is replaced. This crashed without the fix. With the fix we will always remove the ":" prefix and therefore we do not try to handle the "fixed" case. Even, a broken path that contains multiple ":" we would only handle a finite number of times until all ":" are fixed. Change-Id: Ie13cedc1212bb58a16c61e0137128539d189269d Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>