diff options
| author | Max Stepanov <Max.Stepanov@intel.com> | 2014-01-22 14:05:47 +0000 |
|---|---|---|
| committer | Steve Kondik <shade@chemlab.org> | 2014-06-12 14:07:59 -0700 |
| commit | 3131ab317a42d42e82186b91a73907dd3884bac7 (patch) | |
| tree | fa627952e514c4d9139ec4f47a50fe5d2fc3fe8f | |
| parent | eb8a1b7990db7f4464740306b978f56bdcefc5a3 (diff) | |
| download | android_external_wpa_supplicant_8-3131ab317a42d42e82186b91a73907dd3884bac7.tar.gz android_external_wpa_supplicant_8-3131ab317a42d42e82186b91a73907dd3884bac7.tar.bz2 android_external_wpa_supplicant_8-3131ab317a42d42e82186b91a73907dd3884bac7.zip | |
nl80211: Fix sizeof check in vendor command/event handling
Fix sizeof in a validity comparison of nl80211_vendor_cmd_info size. The
incorrect version happened to work on 64-bit builds due the structure
being eight octets, but this was incorrect and would not used with
32-bit builds.
Signed-hostap: Max Stepanov <Max.Stepanov@intel.com>
Git-commit: 080cc445df897592f493d33224f6c3ec01b4a821
Git-repo : git://w1.fi/srv/git/hostap.git
Change-Id: Iba566678c00ecca3d18f79b6a101660e79258488
CRs-Fixed: 598923
| -rw-r--r-- | src/drivers/driver_nl80211.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c index 3437cd78..53ef1a0b 100644 --- a/src/drivers/driver_nl80211.c +++ b/src/drivers/driver_nl80211.c @@ -3401,7 +3401,7 @@ static int wiphy_info_handler(struct nl_msg *msg, void *arg) nla_for_each_nested(nl, tb[NL80211_ATTR_VENDOR_DATA], rem) { struct nl80211_vendor_cmd_info *vinfo; - if (nla_len(nl) != sizeof(vinfo)) { + if (nla_len(nl) != sizeof(*vinfo)) { wpa_printf(MSG_DEBUG, "nl80211: Unexpected vendor data info"); continue; } @@ -3417,7 +3417,7 @@ static int wiphy_info_handler(struct nl_msg *msg, void *arg) nla_for_each_nested(nl, tb[NL80211_ATTR_VENDOR_EVENTS], rem) { struct nl80211_vendor_cmd_info *vinfo; - if (nla_len(nl) != sizeof(vinfo)) { + if (nla_len(nl) != sizeof(*vinfo)) { wpa_printf(MSG_DEBUG, "nl80211: Unexpected vendor data info"); continue; } |
