avoid :121: error: Common realloc mistake: 'resultDevices' nulled but not freed upon failure [cppcheck: memleakOnRealloc]