Explorar o código

isdn: type bug in isdn_net_header()

We use len to store the return value from eth_header().  eth_header()
can return -ETH_HLEN (-14).  We want to pass this back instead of
truncating it to 65522 and returning that.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Dan Carpenter %!s(int64=13) %!d(string=hai) anos
pai
achega
5a46e0f956
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      drivers/isdn/i4l/isdn_net.c

+ 1 - 1
drivers/isdn/i4l/isdn_net.c

@@ -1901,7 +1901,7 @@ static int isdn_net_header(struct sk_buff *skb, struct net_device *dev,
 {
 	isdn_net_local *lp = netdev_priv(dev);
 	unsigned char *p;
-	ushort len = 0;
+	int len = 0;
 
 	switch (lp->p_encap) {
 		case ISDN_NET_ENCAP_ETHER: