Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-11 Thread Ben Pfaff
iginal Message - > From: "Ben Pfaff" > To: "Pavithra Ramesh" > Cc: dev@openvswitch.org > Sent: Monday, February 11, 2013 10:48:28 AM > Subject: Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket > > On Fri, Feb 08, 2013 at 12:37:18PM -0800,

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-11 Thread Pavithra Ramesh
there is no '/' in socket name. Signed-off-by: Pavithra Ramesh Thanks, Pavithra - Original Message - From: "Ben Pfaff" To: "Pavithra Ramesh" Cc: dev@openvswitch.org Sent: Monday, February 11, 2013 10:48:28 AM Subject: Re: [ovs-dev] [PATCH] stream-unix: a

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-11 Thread Ben Pfaff
On Fri, Feb 08, 2013 at 12:37:18PM -0800, Pavithra Ramesh wrote: > If socket path specified is relative to ovs_rundir(), > append the directory name to in unix_open and punix_open. > Made the change in the stream-unix implementation of C and > Python. > Also modified bridge.c to relax the whitelist

[ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-08 Thread Pavithra Ramesh
If socket path specified is relative to ovs_rundir(), append the directory name to in unix_open and punix_open. Made the change in the stream-unix implementation of C and Python. Also modified bridge.c to relax the whitelist check, only if there is no '/' in socket name. --- lib/stream-unix.c

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-08 Thread Ben Pfaff
hanks, > Pavithra > > - Original Message - > From: "Ben Pfaff" > To: "Pavithra Ramesh" > Cc: dev@openvswitch.org > Sent: Friday, February 8, 2013 11:18:38 AM > Subject: Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket > > Yes,

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-08 Thread Pavithra Ramesh
> > - Original Message - > From: "Ben Pfaff" > To: "Pavithra Ramesh" > Cc: dev@openvswitch.org > Sent: Friday, February 8, 2013 9:14:13 AM > Subject: Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket > > On Thu, Feb 07, 2013

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-08 Thread Ben Pfaff
-- > From: "Ben Pfaff" > To: "Pavithra Ramesh" > Cc: dev@openvswitch.org > Sent: Friday, February 8, 2013 9:14:13 AM > Subject: Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket > > On Thu, Feb 07, 2013 at 03:48:14PM -0800, Pavithra Ramesh

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-08 Thread Pavithra Ramesh
Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket On Thu, Feb 07, 2013 at 03:48:14PM -0800, Pavithra Ramesh wrote: > If socket path specified is relative to ovs_rundir(), > append the directory name to in unix_open and punix_open. > Freed the new newly allocated strings.

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-08 Thread Ben Pfaff
On Thu, Feb 07, 2013 at 03:48:14PM -0800, Pavithra Ramesh wrote: > If socket path specified is relative to ovs_rundir(), > append the directory name to in unix_open and punix_open. > Freed the new newly allocated strings. > Also included the change in bridge.c to relax the whitelist > check, only i

[ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-07 Thread Pavithra Ramesh
If socket path specified is relative to ovs_rundir(), append the directory name to in unix_open and punix_open. Freed the new newly allocated strings. Also included the change in bridge.c to relax the whitelist check, only if there is no /. Signed-off-by: Pavithra Ramesh --- lib/stream-unix.c |

[ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-07 Thread Pavithra Ramesh
Incorporated Ben's comments. If socket path specified is relative to ovs_rundir(), append the directory name to in unix_open and punix_open. Also included the change in bridge.c to relax the whitelist check, only if there is no /. Signed-off-by: Pavithra Ramesh --- lib/stream-unix.c | 20 +++

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket If socket path specified is relative to ovs_rundir(), append the directory name to in unix_open.

2013-02-07 Thread Ben Pfaff
On Wed, Feb 06, 2013 at 11:28:55AM -0800, Pavithra Ramesh wrote: > Taken care of the memroy leak, used xasprintf instead. > Also included the change in bridge.c to relax the whitelist > check. > > Signed-off-by: Pavithra Ramesh > --- > lib/stream-unix.c | 11 ++- > vswitchd/bridge.c |

[ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket If socket path specified is relative to ovs_rundir(), append the directory name to in unix_open.

2013-02-06 Thread Pavithra Ramesh
Taken care of the memroy leak, used xasprintf instead. Also included the change in bridge.c to relax the whitelist check. Signed-off-by: Pavithra Ramesh --- lib/stream-unix.c | 11 ++- vswitchd/bridge.c |6 -- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/lib/

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-05 Thread Ben Pfaff
On Tue, Feb 05, 2013 at 05:07:53PM -0800, Pavithra Ramesh wrote: > If socket path specified is relative to ovs_rundir(), > append the directory name to in unix_open. > > Signed-off-by: Pavithra Ramesh Hi Pavithra, I thought that the goal that we discussed in person was this: if the path is not a

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-05 Thread Ethan Jackson
Oh, also I think this may introduce a memory leak. I.E. in the case where connect_path is malloced, it never gets freed. Ethan On Tue, Feb 5, 2013 at 5:08 PM, Ethan Jackson wrote: > This isn't a full review of the patch, but have you considered using > xasprintf() instead of doing the string man

Re: [ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-05 Thread Ethan Jackson
This isn't a full review of the patch, but have you considered using xasprintf() instead of doing the string manipulation by hand? Ethan On Tue, Feb 5, 2013 at 5:07 PM, Pavithra Ramesh wrote: > If socket path specified is relative to ovs_rundir(), > append the directory name to in unix_open. > >

[ovs-dev] [PATCH] stream-unix: append ovs_rundir to socket

2013-02-05 Thread Pavithra Ramesh
If socket path specified is relative to ovs_rundir(), append the directory name to in unix_open. Signed-off-by: Pavithra Ramesh --- lib/stream-unix.c | 12 +++- 1 files changed, 11 insertions(+), 1 deletions(-) diff --git a/lib/stream-unix.c b/lib/stream-unix.c index 6ed7648..8764b6c