aboutsummaryrefslogtreecommitdiffstats
path: root/src/common/wpa_ctrl.c
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2014-12-07 10:52:59 (GMT)
committerJouni Malinen <j@w1.fi>2014-12-08 09:42:07 (GMT)
commit1f102d3bb0b4621e32d3402a6e42a97a71d707d4 (patch)
treeb279a31052f7831817553376ad8901cf7fc67d99 /src/common/wpa_ctrl.c
parenteeab4f2fdaf20b23f1c27c5ce7f655442e2f7902 (diff)
downloadhostap-1f102d3bb0b4621e32d3402a6e42a97a71d707d4.zip
hostap-1f102d3bb0b4621e32d3402a6e42a97a71d707d4.tar.gz
hostap-1f102d3bb0b4621e32d3402a6e42a97a71d707d4.tar.bz2
Check os_snprintf() result more consistently - manual
This converts os_snprintf() result validation cases to use os_snprintf_error() for cases that were note covered by spatch and semantic patches. Signed-off-by: Jouni Malinen <j@w1.fi>
Diffstat (limited to 'src/common/wpa_ctrl.c')
-rw-r--r--src/common/wpa_ctrl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/wpa_ctrl.c b/src/common/wpa_ctrl.c
index a486e45..ccaaf1b 100644
--- a/src/common/wpa_ctrl.c
+++ b/src/common/wpa_ctrl.c
@@ -641,7 +641,7 @@ struct wpa_ctrl * wpa_ctrl_open(const char *ctrl_path)
ret = os_snprintf(name, 256, NAMED_PIPE_PREFIX "-%s",
ctrl_path);
#endif /* UNICODE */
- if (ret < 0 || ret >= 256) {
+ if (os_snprintf_error(256, ret)) {
os_free(ctrl);
return NULL;
}