patch-2.1.112 linux/net/x25/x25_dev.c
Next file: linux/net/x25/x25_facilities.c
Previous file: linux/net/x25/af_x25.c
Back to the patch index
Back to the overall index
- Lines: 39
- Date:
Sun Jul 26 23:35:58 1998
- Orig file:
v2.1.111/linux/net/x25/x25_dev.c
- Orig date:
Thu Feb 12 20:56:15 1998
diff -u --recursive --new-file v2.1.111/linux/net/x25/x25_dev.c linux/net/x25/x25_dev.c
@@ -98,6 +98,7 @@
int x25_lapb_receive_frame(struct sk_buff *skb, struct device *dev, struct packet_type *ptype)
{
struct x25_neigh *neigh;
+ int queued;
skb->sk = NULL;
@@ -113,7 +114,13 @@
switch (skb->data[0]) {
case 0x00:
skb_pull(skb, 1);
- return x25_receive_data(skb, neigh);
+ queued = x25_receive_data(skb, neigh);
+ if( ! queued )
+ /* We need to free the skb ourselves because
+ * net_bh() won't care about our return code.
+ */
+ kfree_skb(skb);
+ return 0;
case 0x01:
x25_link_established(neigh);
@@ -215,6 +222,8 @@
{
unsigned char *dptr;
+ skb->nh.raw = skb->data;
+
switch (neigh->dev->type) {
case ARPHRD_X25:
dptr = skb_push(skb, 1);
@@ -238,3 +247,6 @@
}
#endif
+
+
+
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov