Skip to contentSkip to conversation

remove goto statement

PATCH New Glauber Costa 1 participant 1 message Feb 19, 2008 ACPI

lore
Share & tools
lore
#0 lore raw

PATCH 4/4 remove goto statement

This patch removes goto statements in favour of plain returns in places that had nothing left behind that would justify such construction

---
 drivers/acpi/processor_core.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/acpi/processor_core.c +2 -2
index 06a230a..70f62b6 100644
@@ -651,7 +651,7 @@ static int __cpuinit acpi_processor_star
 
 	result = acpi_processor_add_fs(device);
 	if (result)
-		goto end;
+		return result;
 
 	status = acpi_install_notify_handler(pr->handle, ACPI_DEVICE_NOTIFY,
 					     acpi_processor_notify, pr);
@@ -675,7 +675,7 @@ #endif
 			"%s is registered as cooling_device%d\n",
 			device->dev.bus_id, cdev->id);
 	else
-		goto end;
+		return result;
 
 	result = sysfs_create_link(&device->dev.kobj, &cdev->device.kobj,
 					"thermal_cooling");
Signature · 1 line
1.4.2