Search Linux Wireless

Re: [PATCH 1/3] mt76: mt7615: 0-terminate firmware log messages

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 
> +	skb->data[skb->len] = 0;
>  	wiphy_info(mt76_hw(dev)->wiphy, "%s: %s", type, data);
>  }
> 

Are you sure there's always enough space to write to the skb? Following
the code up I'm not even sure it's always a linear skb :-)

Might be safer/better to do

	wiphy_info(..., "%s: %*s", type, skb->len - sizeof(*rxd),
data);

instead?

johannes





[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux