- Thread::Release() wrote a local variable on the calling thread but read it on
another thread, with no synchronization. Happily it has no non-test callers
so deleting it instead of trying to fix it (see bug for details).
- Thread::started_ similarly was racily being written to; replaced with a
running_ Event, and hid the accessor except for tests & legacy callers,
with a note about why it's a bad idea.
webrtc/base patched with:
git diff origin --relative=talk/base | patch -p1 -dwebrtc/base
followed by manual merge of 3 thunks that ran afoul of naming differences
between talk/base and webrtc/base.
BUG=3388
R=andrew@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/14589005
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6236 4adac7df-926f-26a2-2b94-8c16560cd09d
port leak.
The port rights obtained by mach_host_self() and mach_thread_self() need
to be deallocated with mach_port_deallocate(). They consume finite
system-wide resources. This is in contrast to mach_task_self(), which is
a macro that wraps an extern global variable, and must not be
deallocated.
http://crbug.com/105513 shows the sorts of problems that can occur when
these aren't properly deallocated.
R=fischman@webrtc.org, tkchin@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/15469004
Patch from Mark Mentovai <mark@chromium.org>.
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6131 4adac7df-926f-26a2-2b94-8c16560cd09d
Example run from cmd-line:
ninja -C out_ios/Debug-iphoneos libjingle_unittest && \
~/src/ios-deploy/ios-deploy -d -u -v -b \
~/src/wr/trunk/out_ios/Debug-iphoneos/libjingle_unittest.app
Note that the test's use of signals means that lldb will break in the middle
of the suite. To ignore these signals tell lldb:
pro hand -p true -s false -n false SIGINT
pro hand -p true -s false -n false SIGTERM
continue
BUG=3241
R=kjellander@webrtc.org, tkchin@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/21369004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6025 4adac7df-926f-26a2-2b94-8c16560cd09d
Example run from cmd-line:
ninja -C out_ios/Debug-iphoneos libjingle_unittest && ~/src/ios-deploy/ios-deploy -d -u -v -b ~/src/wr/trunk/out_ios/Debug-iphoneos/libjingle_unittest.app
Note that the test's use of signals means that lldb will break in the middle of the suite. To ignore these signals tell lldb:
pro hand -p true -s false -n false SIGINT
pro hand -p true -s false -n false SIGTERM
continue
BUG=3241
R=noahric@google.com, tkchin@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/12229004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5986 4adac7df-926f-26a2-2b94-8c16560cd09d
Chromium defines ENABLE_PROFILING under the gyp flag profiling=1. This
corrects the resulting mulitple defintion error:
../../talk/base/profiler.h:61:9: error: 'ENABLE_PROFILING' macro redefined [-Werror]
#define ENABLE_PROFILING
and allows us to use profiling=1 in standalone builds.
TESTED=build passes with profiling=1
R=wu@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/10829004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5804 4adac7df-926f-26a2-2b94-8c16560cd09d
std::memcpy -> memcpy for instance. This change was motivated by a
compile report complaining that std::rand() was used instead of rand(),
probably with a stdlib.h include instead of cstdlib. Use of C functions
without the std:: prefix is a lot more common, so removing std:: to
address this.
BUG=
R=tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/9559004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5657 4adac7df-926f-26a2-2b94-8c16560cd09d
Because chromium is compiled with a different version of logging macros
defined in logging.h that header cannot be used in headers that can
also included from chromium code. Removed LOG_F(LS_WARNING) from
callback.h . That issue would block this code from being rolled in
chromium.
R=mallinath@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/8279004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5507 4adac7df-926f-26a2-2b94-8c16560cd09d
It includes unit test fixes to properly initialize SSL if DTLS or SSL random number generator is used in the tests.
The private key and certificate constant strings used in some tests are updated to be compatible with NSS.
A few potentially overflow type conversions caused compiling warning on Windows and they are fixed by importing and using Chromium's checked_cast, which aborts the program if overflow occurs.
It also fixes a leak in nssstreamadapter.cc by releasing the PRFileDesc* in StreamClose.
BUG=2253
R=fischman@webrtc.org, juberti@google.com, wu@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/4679005
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5459 4adac7df-926f-26a2-2b94-8c16560cd09d