summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2015-11-22 12:36:28 +0100
committerFelix Fietkau <nbd@openwrt.org>2015-11-22 12:37:10 +0100
commit22a64fe3e9a7b5dcf97d0b240f2ce09919f4b02f (patch)
tree9ca02024394a89ceb0ccf4511d68f0e8f99cf93b
parent3a599ba4541b2c428e3467650b9ad0a2364b41e6 (diff)
wds: cast pdp_type enum to int to avoid clang considering the range check tautological
enum overflow behavior is undefined Signed-off-by: Felix Fietkau <nbd@openwrt.org>
-rw-r--r--commands-wds.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/commands-wds.c b/commands-wds.c
index fca5fe7..0615a7a 100644
--- a/commands-wds.c
+++ b/commands-wds.c
@@ -246,7 +246,7 @@ cmd_wds_get_current_settings_cb(struct qmi_dev *qmi, struct qmi_request *req, st
t = blobmsg_open_table(&status, NULL);
- if (res.set.pdp_type && res.data.pdp_type < ARRAY_SIZE(pdptypes))
+ if (res.set.pdp_type && (int) res.data.pdp_type < ARRAY_SIZE(pdptypes))
blobmsg_add_string(&status, "pdp-type", pdptypes[res.data.pdp_type]);
if (res.set.ip_family) {