Angel Pons has uploaded this change for review.

View Change

dediprog.c: Split up compound conditional statement

For clarity, move the `dediprog_set_leds` call out of the if-block. As
this function can only return 0 or 1, directly return its return value.

Change-Id: Ib7e0179da39279e32a8497466b044b69ec836da8
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
---
M dediprog.c
1 file changed, 2 insertions(+), 2 deletions(-)

git pull ssh://review.coreboot.org:29418/flashrom refs/changes/06/51706/1
diff --git a/dediprog.c b/dediprog.c
index c50e374..f886997 100644
--- a/dediprog.c
+++ b/dediprog.c
@@ -1273,8 +1273,8 @@
if (protocol() == PROTOCOL_V2)
spi_master_dediprog.features |= SPI_MASTER_4BA;

- if (register_spi_master(&spi_master_dediprog) || dediprog_set_leds(LED_NONE))
+ if (register_spi_master(&spi_master_dediprog))
return 1;

- return 0;
+ return dediprog_set_leds(LED_NONE);
}

To view, visit change 51706. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ib7e0179da39279e32a8497466b044b69ec836da8
Gerrit-Change-Number: 51706
Gerrit-PatchSet: 1
Gerrit-Owner: Angel Pons <th3fanbus@gmail.com>
Gerrit-MessageType: newchange