summaryrefslogtreecommitdiff
path: root/sal
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-02-02 12:22:32 +0100
committerStephan Bergmann <sbergman@redhat.com>2015-02-02 12:22:32 +0100
commite76bc369b8ee58094f45a2f5451cf9374163e979 (patch)
tree75d4ffcd3824d9c53aac72098a9abfdf202416da /sal
parentc8bd2518dda4593681626c4780f492995dff66e3 (diff)
warning C4701: potentially uninitialized local variable 'Addr' used
Change-Id: I63c22fb682175edc450b1ce3b6ea78cf5a5bc2f1
Diffstat (limited to 'sal')
-rw-r--r--sal/osl/w32/socket.cxx5
1 files changed, 1 insertions, 4 deletions
diff --git a/sal/osl/w32/socket.cxx b/sal/osl/w32/socket.cxx
index a6487fa0dae0..8722142e71cb 100644
--- a/sal/osl/w32/socket.cxx
+++ b/sal/osl/w32/socket.cxx
@@ -651,10 +651,7 @@ oslSocketAddr SAL_CALL osl_createInetSocketAddr (
#ifdef _WIN32_WINNT_WINBLUE
IN_ADDR addr;
INT ret = InetPtonW(AF_INET, strDottedAddr->buffer, & addr);
- if (1 == ret)
- {
- Addr = addr.S_un.S_addr;
- }
+ Addr = ret == 1 ? addr.S_un.S_addr : OSL_INADDR_NONE;
#else
rtl_String *pDottedAddr=NULL;