aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@mandriva.com>2005-09-22 02:38:15 -0400
committerArnaldo Carvalho de Melo <acme@mandriva.com>2005-09-22 02:38:15 -0400
commitbdcc66cca89cc2e97e93054d139b2e9a2b2ec1a7 (patch)
treeb63038631b65b0ed00366bc6bd74c5700f1bc8b3 /net
parent1d67e6501b8dba54ef8dcabebe2ad049b8ad0d67 (diff)
[LLC]: Simplify llc_c_ac code, removing unneeded assignments to variables
Signed-off-by: Jochen Friedrich <jochen@scram.de> Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
Diffstat (limited to 'net')
-rw-r--r--net/llc/llc_c_ac.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/net/llc/llc_c_ac.c b/net/llc/llc_c_ac.c
index db98ea2113a5..309c5682e58d 100644
--- a/net/llc/llc_c_ac.c
+++ b/net/llc/llc_c_ac.c
@@ -120,10 +120,8 @@ int llc_conn_ac_disc_ind(struct sock *sk, struct sk_buff *skb)
120 reason = LLC_DISC_REASON_RX_DISC_CMD_PDU; 120 reason = LLC_DISC_REASON_RX_DISC_CMD_PDU;
121 } else if (ev->type == LLC_CONN_EV_TYPE_ACK_TMR) 121 } else if (ev->type == LLC_CONN_EV_TYPE_ACK_TMR)
122 reason = LLC_DISC_REASON_ACK_TMR_EXP; 122 reason = LLC_DISC_REASON_ACK_TMR_EXP;
123 else { 123 else
124 reason = 0;
125 rc = -EINVAL; 124 rc = -EINVAL;
126 }
127 if (!rc) { 125 if (!rc) {
128 ev->reason = reason; 126 ev->reason = reason;
129 ev->ind_prim = LLC_DISC_PRIM; 127 ev->ind_prim = LLC_DISC_PRIM;
@@ -160,9 +158,6 @@ int llc_conn_ac_rst_ind(struct sock *sk, struct sk_buff *skb)
160 LLC_U_PDU_CMD(pdu) == LLC_2_PDU_CMD_SABME) { 158 LLC_U_PDU_CMD(pdu) == LLC_2_PDU_CMD_SABME) {
161 reason = LLC_RESET_REASON_REMOTE; 159 reason = LLC_RESET_REASON_REMOTE;
162 rc = 0; 160 rc = 0;
163 } else {
164 reason = 0;
165 rc = 1;
166 } 161 }
167 break; 162 break;
168 case LLC_CONN_EV_TYPE_ACK_TMR: 163 case LLC_CONN_EV_TYPE_ACK_TMR:
@@ -172,8 +167,7 @@ int llc_conn_ac_rst_ind(struct sock *sk, struct sk_buff *skb)
172 if (llc->retry_count > llc->n2) { 167 if (llc->retry_count > llc->n2) {
173 reason = LLC_RESET_REASON_LOCAL; 168 reason = LLC_RESET_REASON_LOCAL;
174 rc = 0; 169 rc = 0;
175 } else 170 }
176 rc = 1;
177 break; 171 break;
178 } 172 }
179 if (!rc) { 173 if (!rc) {