From: Jeff Layton Date: Wed, 27 Apr 2011 17:25:51 +0000 (-0400) Subject: cifs: check for bytes_remaining going to zero in CIFS_SessSetup X-Git-Tag: v2.6.39-rc7~9^2~3 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fcda7f4578bbf9717444ca6da8a421d21489d078;p=pandora-kernel.git cifs: check for bytes_remaining going to zero in CIFS_SessSetup It's possible that when we go to decode the string area in the SESSION_SETUP response, that bytes_remaining will be 0. Decrementing it at that point will mean that it can go "negative" and wrap. Check for a bytes_remaining value of 0, and don't try to decode the string area if that's the case. Cc: stable@kernel.org Reported-and-Acked-by: David Howells Signed-off-by: Jeff Layton Signed-off-by: Steve French --- Reading git-diff-tree failed