Commit e6cb876
wifi: airo: do not assign -1 to unsigned char
With char becoming unsigned by default, and with `char` alone being
ambiguous and based on architecture, we get a warning when assigning the
unchecked output of hex_to_bin() to that unsigned char. Mark `key` as a
`u8`, which matches the struct's type, and then check each call to
hex_to_bin() before casting.
Cc: Kalle Valo <kvalo@kernel.org>
Cc: linux-wireless@vger.kernel.org
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20221024162843.535921-1-Jason@zx2c4.com1 parent 69188df commit e6cb876
1 file changed
+14
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5232 | 5232 | | |
5233 | 5233 | | |
5234 | 5234 | | |
5235 | | - | |
| 5235 | + | |
5236 | 5236 | | |
5237 | 5237 | | |
5238 | 5238 | | |
| |||
5283 | 5283 | | |
5284 | 5284 | | |
5285 | 5285 | | |
5286 | | - | |
| 5286 | + | |
5287 | 5287 | | |
5288 | 5288 | | |
5289 | 5289 | | |
| |||
5311 | 5311 | | |
5312 | 5312 | | |
5313 | 5313 | | |
| 5314 | + | |
| 5315 | + | |
| 5316 | + | |
| 5317 | + | |
| 5318 | + | |
| 5319 | + | |
| 5320 | + | |
| 5321 | + | |
| 5322 | + | |
| 5323 | + | |
5314 | 5324 | | |
5315 | 5325 | | |
5316 | | - | |
| 5326 | + | |
5317 | 5327 | | |
5318 | 5328 | | |
5319 | | - | |
| 5329 | + | |
5320 | 5330 | | |
5321 | 5331 | | |
5322 | 5332 | | |
| |||
0 commit comments