stream_init() didn't initialize the remote_ip, remote_port, local_ip, or
local_port members of the stream, so "unix" streams that don't have any of
those would get random values instead.

Reported-by: "Voravit T." <[email protected]>
Reported-by: Jari Sundell <[email protected]>
---
 AUTHORS      |    2 ++
 lib/stream.c |    1 +
 2 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/AUTHORS b/AUTHORS
index d19d665..0d4cc95 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -77,6 +77,7 @@ Henrik Amren            [email protected]
 Jad Naous               [email protected]
 Jan Medved              [email protected]
 Janis Hamme             [email protected]
+Jari Sundell            [email protected]
 Jed Daniels             [email protected]
 Jeongkeun Lee           [email protected]
 Joan Cirer              [email protected]
@@ -105,6 +106,7 @@ Takayuki HAMA           [email protected]
 Teemu Koponen           [email protected]
 Tyler Coumbes           [email protected]
 Vishal Swarankar        [email protected]
+Voravit T.              [email protected]
 YAMAMOTO Takashi        [email protected]
 Yongqiang Liu           [email protected]
 kk yap                  [email protected]
diff --git a/lib/stream.c b/lib/stream.c
index 37b6110..8f567ca 100644
--- a/lib/stream.c
+++ b/lib/stream.c
@@ -616,6 +616,7 @@ void
 stream_init(struct stream *stream, struct stream_class *class,
             int connect_status, const char *name)
 {
+    memset(stream, 0, sizeof *stream);
     stream->class = class;
     stream->state = (connect_status == EAGAIN ? SCS_CONNECTING
                     : !connect_status ? SCS_CONNECTED
-- 
1.7.4.4

_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev

Reply via email to