11 Commits

Author SHA1 Message Date
deadbeef
4483af35e9 Relanding #2: Fixing crash that can occur if signal is modified while firing.
The crash occurs if a slot causes the very next slot in iteration order
to be disconnected.

Relanding after fixing a race condition that this CL revealed. Previously
the race resulted in an invalidated iterator, but now it will result in the
iterator being modified, so TSan catches it.

BUG=webrtc:7527

Review-Url: https://codereview.webrtc.org/2846593005
Cr-Commit-Position: refs/heads/master@{#18124}
2017-05-12 15:44:38 +00:00
perkj
de1590919f Revert of Relanding: Fixing crash that can occur if signal is modified while firing. (patchset #4 id:60001 of https://codereview.webrtc.org/2846593005/ )
Reason for revert:
Breaks XmppConnectionTest in Chrome.

https://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_tsan_rel_ng/builds/65096

Original issue's description:
> Relanding: Fixing crash that can occur if signal is modified while firing.
>
> The crash occurs if a slot causes the very next slot in iteration order
> to be disconnected.
>
> Relanding after fixing a race condition that this CL revealed. Previously
> the race resulted in an invalidated iterator, but now it will result in the
> iterator being modified, so TSan catches it.
>
> BUG=webrtc:7527
>
> Review-Url: https://codereview.webrtc.org/2846593005
> Cr-Original-Commit-Position: refs/heads/master@{#17943}
> Committed: 961c2adf1e
> Review-Url: https://codereview.webrtc.org/2846593005
> Cr-Commit-Position: refs/heads/master@{#17965}
> Committed: fc1af01557

TBR=pthatcher@webrtc.org,deadbeef@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7527

Review-Url: https://codereview.webrtc.org/2859443002
Cr-Commit-Position: refs/heads/master@{#17975}
2017-05-02 13:14:59 +00:00
deadbeef
fc1af01557 Relanding: Fixing crash that can occur if signal is modified while firing.
The crash occurs if a slot causes the very next slot in iteration order
to be disconnected.

Relanding after fixing a race condition that this CL revealed. Previously
the race resulted in an invalidated iterator, but now it will result in the
iterator being modified, so TSan catches it.

BUG=webrtc:7527

Review-Url: https://codereview.webrtc.org/2846593005
Cr-Original-Commit-Position: refs/heads/master@{#17943}
Committed: 961c2adf1e
Review-Url: https://codereview.webrtc.org/2846593005
Cr-Commit-Position: refs/heads/master@{#17965}
2017-05-02 05:24:20 +00:00
deadbeef
86746c475f Revert of Fixing crash that can occur if signal is modified while firing. (patchset #3 id:40001 of https://codereview.webrtc.org/2846593005/ )
Reason for revert:
Revealed a race condition (now reported by TSan), and breaks the scenario where a signal is deleted while firing.

Original issue's description:
> Fixing crash that can occur if signal is modified while firing.
>
> The crash occurs if a slot causes the very next slot in iteration order
> to be disconnected.
>
> BUG=webrtc:7527
>
> Review-Url: https://codereview.webrtc.org/2846593005
> Cr-Commit-Position: refs/heads/master@{#17943}
> Committed: 961c2adf1e

TBR=pthatcher@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7527

Review-Url: https://codereview.webrtc.org/2847243006
Cr-Commit-Position: refs/heads/master@{#17947}
2017-04-29 19:00:21 +00:00
deadbeef
961c2adf1e Fixing crash that can occur if signal is modified while firing.
The crash occurs if a slot causes the very next slot in iteration order
to be disconnected.

BUG=webrtc:7527

Review-Url: https://codereview.webrtc.org/2846593005
Cr-Commit-Position: refs/heads/master@{#17943}
2017-04-29 08:39:52 +00:00
deadbeef
8b1d862bfe Fixing sigslot copy constructors.
They used to work, but were broken by a somewhat recent refactoring of
sigslot.h.

It's reasonable for signals and slots to have copy constructors, since
a class that uses signals/slots may want to be copyable.

BUG=webrtc:7342

Review-Url: https://codereview.webrtc.org/2842423002
Cr-Commit-Position: refs/heads/master@{#17942}
2017-04-29 07:27:04 +00:00
deadbeef
37f5ecfd8f Replace NULL with nullptr or null in webrtc/base/.
BUG=webrtc:7147

Review-Url: https://codereview.webrtc.org/2718663005
Cr-Commit-Position: refs/heads/master@{#16878}
2017-02-27 22:06:41 +00:00
deadbeef
8d517c4170 Rewrite of sigslot that avoids vtables.
This reduces binary size considerably and solves some other problems.

Also rewrote using variadic templates.

Initial patch contributed by andrey.semashev@gmail.com.

BUG=webrtc:2305

Review-Url: https://codereview.webrtc.org/2509733003
Cr-Commit-Position: refs/heads/master@{#16703}
2017-02-19 22:12:24 +00:00
henrike@webrtc.org
f048872e91 Adds a modified copy of talk/base to webrtc/base. It is the first step in
migrating talk/base to webrtc/base.

BUG=N/A
R=niklas.enbom@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/17479005

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6129 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-05-13 18:00:26 +00:00
perkj@webrtc.org
e9a604accd Revert 6107 "Adds a modified copy of talk/base to webrtc/base. I..."
This breaks Chromium FYI builds and prevent roll of webrtc/libjingle to Chrome.

http://chromegw.corp.google.com/i/chromium.webrtc.fyi/builders/Win%20Builder/builds/457


> Adds a modified copy of talk/base to webrtc/base. It is the first step in migrating talk/base to webrtc/base.
> 
> BUG=N/A
> R=andrew@webrtc.org, wu@webrtc.org
> 
> Review URL: https://webrtc-codereview.appspot.com/12199004

TBR=henrike@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/14479004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6116 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-05-13 08:15:48 +00:00
henrike@webrtc.org
2c7d1b39b9 Adds a modified copy of talk/base to webrtc/base. It is the first step in migrating talk/base to webrtc/base.
BUG=N/A
R=andrew@webrtc.org, wu@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/12199004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6107 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-05-12 18:03:09 +00:00