diff options
author | David Sommerseth <dazo@users.sourceforge.net> | 2011-04-26 23:04:18 +0200 |
---|---|---|
committer | David Sommerseth <dazo@users.sourceforge.net> | 2011-04-26 23:04:18 +0200 |
commit | 20b18fd799e2ea9d0651f3ef913dd9ce2e481471 (patch) | |
tree | 86867a1128f35087f37d4b49ecf241b7b8e6b38e /service-win32 | |
parent | Merge branch 'feat_ipv6_payload' (diff) | |
parent | Fixed compile issues on Windows. (diff) | |
download | openvpn-20b18fd799e2ea9d0651f3ef913dd9ce2e481471.tar.xz |
Merge branch 'svn-branch-2.1' into merge
Pulling in changes from James' 2.1/openvpn branch in SVN.
Conflicts:
buffer.c
init.c
manage.h
multi.c
openvpn.8
options.c
ssl.c
version.m4
win/sign.py
Signed-off-by: David Sommerseth <dazo@users.sourceforge.net>
Diffstat (limited to 'service-win32')
-rwxr-xr-x | service-win32/openvpnserv.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/service-win32/openvpnserv.c b/service-win32/openvpnserv.c index 5b0eb6e..0993064 100755 --- a/service-win32/openvpnserv.c +++ b/service-win32/openvpnserv.c @@ -133,15 +133,15 @@ static HANDLE exit_event = NULL; int openvpn_snprintf(char *str, size_t size, const char *format, ...) { va_list arglist; - int ret = 0; + int len = -1; if (size > 0) { va_start (arglist, format); - ret = vsnprintf (str, size, format, arglist); + len = vsnprintf (str, size, format, arglist); va_end (arglist); str[size - 1] = 0; } - return ret; + return (len >= 0 && len < size); } |