OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012, Google Inc. All rights reserved. | 2 * Copyright (C) 2012, Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 m_context->removeMarkedSummingJunction(this); | 49 m_context->removeMarkedSummingJunction(this); |
50 } | 50 } |
51 | 51 |
52 AudioSummingJunction::~AudioSummingJunction() | 52 AudioSummingJunction::~AudioSummingJunction() |
53 { | 53 { |
54 } | 54 } |
55 | 55 |
56 DEFINE_TRACE(AudioSummingJunction) | 56 DEFINE_TRACE(AudioSummingJunction) |
57 { | 57 { |
58 visitor->trace(m_context); | 58 visitor->trace(m_context); |
| 59 // FIXME: Oilpan: m_renderingOutputs should not be strong references. This |
| 60 // is a short-term workaround to avoid crashes, and causes AudioNode leaks. |
| 61 AudioContext::AutoLocker locker(m_context); |
| 62 for (size_t i = 0; i < m_renderingOutputs.size(); ++i) |
| 63 visitor->trace(m_renderingOutputs[i]); |
59 } | 64 } |
60 | 65 |
61 void AudioSummingJunction::changedOutputs() | 66 void AudioSummingJunction::changedOutputs() |
62 { | 67 { |
63 ASSERT(context()->isGraphOwner()); | 68 ASSERT(context()->isGraphOwner()); |
64 if (!m_renderingStateNeedUpdating && !m_didCallDispose) { | 69 if (!m_renderingStateNeedUpdating && !m_didCallDispose) { |
65 context()->markSummingJunctionDirty(this); | 70 context()->markSummingJunctionDirty(this); |
66 m_renderingStateNeedUpdating = true; | 71 m_renderingStateNeedUpdating = true; |
67 } | 72 } |
68 } | 73 } |
(...skipping 13 matching lines...) Expand all Loading... |
82 | 87 |
83 didUpdate(); | 88 didUpdate(); |
84 | 89 |
85 m_renderingStateNeedUpdating = false; | 90 m_renderingStateNeedUpdating = false; |
86 } | 91 } |
87 } | 92 } |
88 | 93 |
89 } // namespace blink | 94 } // namespace blink |
90 | 95 |
91 #endif // ENABLE(WEB_AUDIO) | 96 #endif // ENABLE(WEB_AUDIO) |
OLD | NEW |