Index: device/bluetooth/bluetooth_audio_sink.h |
diff --git a/device/bluetooth/bluetooth_audio_sink.h b/device/bluetooth/bluetooth_audio_sink.h |
index f5826c1d83184aeae5126c6883d66ae2ca3d5834..331ef0d83d1dac7653b745d899a694339ae7fce2 100644 |
--- a/device/bluetooth/bluetooth_audio_sink.h |
+++ b/device/bluetooth/bluetooth_audio_sink.h |
@@ -12,6 +12,7 @@ |
#include "base/callback.h" |
#include "base/memory/ref_counted.h" |
#include "base/memory/scoped_ptr.h" |
+#include "device/bluetooth/bluetooth_export.h" |
namespace device { |
@@ -23,7 +24,8 @@ namespace device { |
// the interface provided by BluetoothAdapter. The validity of a |
// BluetoothAudioSink depends on whether BluetoothAdapter is present and whether |
// it is powered. |
-class BluetoothAudioSink : public base::RefCounted<BluetoothAudioSink> { |
+class DEVICE_BLUETOOTH_EXPORT BluetoothAudioSink |
+ : public base::RefCounted<BluetoothAudioSink> { |
public: |
// Possible values indicating the connection states between the |
// BluetoothAudioSink and the remote device. |
@@ -98,6 +100,9 @@ class BluetoothAudioSink : public base::RefCounted<BluetoothAudioSink> { |
protected: |
friend class base::RefCounted<BluetoothAudioSink>; |
BluetoothAudioSink(); |
+ |
+ // The destructor invokes Unregister() to ensure the audio sink will be |
+ // unregistered even if the user applications fail to do so. |
virtual ~BluetoothAudioSink(); |
private: |