[lkml]   [2011]   [Feb]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: x25: possible skb leak on bad facilities
From: Andrew Hendry <>
Date: Mon, 07 Feb 2011 21:08:15 +1100

> Originally x25_parse_facilities returned
> -1 for an error
> 0 meaning 0 length facilities
>>0 the length of the facilities parsed.
> 5ef41308f94dc introduced more error checking in x25_parse_facilities
> however used 0 to indicate bad parsing
> a6331d6f9a429 followed this further for DTE facilities, again using 0 for bad parsing.
> The meaning of 0 got confused in the callers.
> If the facilities are messed up we can't determine where the data starts.
> So patch makes all parsing errors return -1 and ensures callers close and don't use the skb further.
> Reported-by: Andy Whitcroft <>
> Signed-off-by: Andrew Hendry <>

Please reference the commit header line text when referring to SHA1
IDs, because when backporting to other GIT trees the SHA1 IDs might be

I took care of this when applying your patch, thanks.

 \ /
  Last update: 2011-02-07 22:45    [W:0.029 / U:2.068 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site