else {
mode = findRandRMode(output, iter->dimensions.width(),
iter->dimensions.height());
- if (!ret) {
+ if (mode == NULL) {
vlog.error("Failed to find a suitable mode for %dx%d for output '%s'",
iter->dimensions.width(), iter->dimensions.height(),
output->name);
mode = findRandRMode(output, iter->dimensions.width(),
iter->dimensions.height());
- if (!ret) {
+ if (mode == NULL) {
vlog.error("Failed to find a suitable mode for %dx%d for output '%s'",
iter->dimensions.width(), iter->dimensions.height(),
output->name);