Yeah, I was not sure about this either. I was trying to avoid pulling any ovs specific library to the 'libbfd' and considering that bfd_set_next_tx() (which uses rand()) will only be called while holding the global lock.
I agree that this will leave risk for future development. I think I will just move the needed random.c code into the bfd.c. Thanks, Alex Wang, On Mon, Mar 3, 2014 at 5:49 PM, Ben Pfaff <b...@nicira.com> wrote: > On Mon, Mar 03, 2014 at 05:46:41PM -0800, Alex Wang wrote: > > This commit replaces the current bfd.{c,h} with a generic library-like > > implementation. Wrappers (in bfd_ts.{c,h}) are then added to guarantee > > the thread-safety and compatibility with current invocation pattern. > > > > Signed-off-by: Alex Wang <al...@nicira.com> > > ... > > > diff --git a/build-aux/thread-safety-blacklist > b/build-aux/thread-safety-blacklist > > index 42560df..4db5a84 100644 > > --- a/build-aux/thread-safety-blacklist > > +++ b/build-aux/thread-safety-blacklist > > @@ -70,7 +70,6 @@ > > \bputchar_unlocked( > > \bputenv( > > \bpututxline( > > -\brand( > > \bsetenv( > > \bsetgrent( > > \bsetkey( > > Why are we removing this? rand() really isn't thread-safe. >
_______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev