Skip to contentSkip to conversation

Staging: iio: ade7758: Remove braces on a single statement if

PATCH In review Taiane Coelho Ramos 3 participants 3 messages Mar 13, 2015 – Mar 16, 2015

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 Staging: iio: ade7758: Remove braces on a single statement if

This patch fixes the checkpatch.pl warning:

WARNING: braces {} are not necessary for single
statement blocks

---
Changes in v2:
- Make the commit message more clear.

 drivers/staging/iio/meter/ade7758_ring.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/staging/iio/meter/ade7758_ring.c +1 -2
index 9725a04..ead38a5 100644
@@ -119,9 +119,8 @@ int ade7758_configure_ring(struct iio_dev *indio_dev)
 	int ret = 0;
 
 	buffer = iio_kfifo_allocate();
-	if (!buffer) {
+	if (!buffer)
 		return -ENOMEM;
-	}
 
 	iio_device_attach_buffer(indio_dev, buffer);
 
Signature · 1 line
1.9.3
Reviewed-by on v2 1/1
#1 lore raw
Quoted 6 lines · Taiane Coelho Ramos

This patch fixes the checkpatch.pl warning:

WARNING: braces {} are not necessary for single
statement blocks

Quoted 31 lines

---
Changes in v2:
- Make the commit message more clear.

 drivers/staging/iio/meter/ade7758_ring.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/staging/iio/meter/ade7758_ring.c +1 -3
index 9725a04..ead38a5 100644
@@ -119,9 +119,8 @@ int ade7758_configure_ring(struct iio_dev *indio_dev)
        int ret = 0;
 
        buffer = iio_kfifo_allocate();
-       if (!buffer) {
+       if (!buffer)
                return -ENOMEM;
-       }
 
        iio_device_attach_buffer(indio_dev, buffer);
 
--

1.9.3

--
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/1426274564-4074-1-git-send-email-exhora.tat%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

maintainer
#2 lore raw
In reply to Taiane Coelho Ramos
Quoted 5 lines · Taiane Coelho Ramos

This patch fixes the checkpatch.pl warning:

WARNING: braces {} are not necessary for single
statement blocks

Quoted 8 lines

---
Changes in v2:
- Make the commit message more clear.

 drivers/staging/iio/meter/ade7758_ring.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

This does not apply to my tree :(