diff options
author | Bjorn Helgaas <bhelgaas@google.com> | 2014-03-04 17:35:44 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-03-06 16:07:25 -0500 |
commit | 4ae6e50c76def306d726a5d2678e88998ad5258e (patch) | |
tree | f22db725208c33c358048396af21b38e1a00e926 /include/net/sock.h | |
parent | e588e2f286ed7da011ed357c24c5b9a554e26595 (diff) | |
download | linux-stable-4ae6e50c76def306d726a5d2678e88998ad5258e.tar.gz linux-stable-4ae6e50c76def306d726a5d2678e88998ad5258e.tar.bz2 linux-stable-4ae6e50c76def306d726a5d2678e88998ad5258e.zip |
phy: fix compiler array bounds warning on settings[]
With -Werror=array-bounds, gcc v4.7.x warns that in phy_find_valid(), the
settings[] "array subscript is above array bounds", I think because idx is
a signed integer and if the caller supplied idx < 0, we pass the guard but
still reference out of bounds.
Fix this by making idx unsigned here and elsewhere.
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/sock.h')
0 files changed, 0 insertions, 0 deletions