Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1574949 > unrolled thread
| Started by | Maksymilian Piechota <maksymilianpiechota@gmail.com> |
|---|---|
| First post | 2017-02-06 17:20 +0100 |
| Last post | 2017-02-06 19:00 +0100 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH v4 2/2] staging: lustre: move else if statement to a single line Maksymilian Piechota <maksymilianpiechota@gmail.com> - 2017-02-06 17:20 +0100
Re: [PATCH v4 2/2] staging: lustre: move else if statement to a single line Joe Perches <joe@perches.com> - 2017-02-06 19:00 +0100
| From | Maksymilian Piechota <maksymilianpiechota@gmail.com> |
|---|---|
| Date | 2017-02-06 17:20 +0100 |
| Subject | [PATCH v4 2/2] staging: lustre: move else if statement to a single line |
| Message-ID | <t7Ubh-7e3-31@gated-at.bofh.it> |
Signed-off-by: Maksymilian Piechota <maksymilianpiechota@gmail.com>
---
drivers/staging/wlan-ng/prism2mgmt.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/staging/wlan-ng/prism2mgmt.c b/drivers/staging/wlan-ng/prism2mgmt.c
index 64a9ebc..af83f2a 100644
--- a/drivers/staging/wlan-ng/prism2mgmt.c
+++ b/drivers/staging/wlan-ng/prism2mgmt.c
@@ -1307,8 +1307,7 @@ int prism2mgmt_wlansniff(struct wlandevice *wlandev, void *msgp)
&& (msg->prismheader.data == P80211ENUM_truth_true)) {
hw->sniffhdr = 0;
wlandev->netdev->type = ARPHRD_IEEE80211_PRISM;
- } else
- if ((msg->wlanheader.status == P80211ENUM_msgitem_status_data_ok) &&
+ } else if ((msg->wlanheader.status == P80211ENUM_msgitem_status_data_ok) &&
(msg->wlanheader.data == P80211ENUM_truth_true)) {
hw->sniffhdr = 1;
wlandev->netdev->type = ARPHRD_IEEE80211_PRISM;
--
2.1.4
[toc] | [next] | [standalone]
| From | Joe Perches <joe@perches.com> |
|---|---|
| Date | 2017-02-06 19:00 +0100 |
| Subject | Re: [PATCH v4 2/2] staging: lustre: move else if statement to a single line |
| Message-ID | <t7VK2-8by-11@gated-at.bofh.it> |
| In reply to | #1574949 |
On Mon, 2017-02-06 at 11:13 -0500, Maksymilian Piechota wrote:
> diff --git a/drivers/staging/wlan-ng/prism2mgmt.c b/drivers/staging/wlan-ng/prism2mgmt.c
[]
> @@ -1307,8 +1307,7 @@ int prism2mgmt_wlansniff(struct wlandevice *wlandev, void *msgp)
> && (msg->prismheader.data == P80211ENUM_truth_true)) {
> hw->sniffhdr = 0;
> wlandev->netdev->type = ARPHRD_IEEE80211_PRISM;
> - } else
> - if ((msg->wlanheader.status == P80211ENUM_msgitem_status_data_ok) &&
> + } else if ((msg->wlanheader.status == P80211ENUM_msgitem_status_data_ok) &&
> (msg->wlanheader.data == P80211ENUM_truth_true)) {
> hw->sniffhdr = 1;
> wlandev->netdev->type = ARPHRD_IEEE80211_PRISM;
Hi again.
When you change the else if on multiple lines to a single line,
you should also realign the continuation like:
} else if ((msg->wlanheader.status == P80211ENUM_msgitem_status_data_ok) &&
(msg->wlanheader.data == P80211ENUM_truth_true)) {
Using 3 tabs then 3 spaces
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web