Index: webrtc/media/engine/webrtcvideocapturerfactory.cc |
diff --git a/webrtc/media/engine/webrtcvideocapturerfactory.cc b/webrtc/media/engine/webrtcvideocapturerfactory.cc |
index 3cf360953b9d9190d2d454610107fb54534f43f5..6ee361a0dfe1090f643d4330d60a72fcab5be07a 100644 |
--- a/webrtc/media/engine/webrtcvideocapturerfactory.cc |
+++ b/webrtc/media/engine/webrtcvideocapturerfactory.cc |
@@ -15,16 +15,17 @@ |
namespace cricket { |
-VideoCapturer* WebRtcVideoDeviceCapturerFactory::Create(const Device& device) { |
+std::unique_ptr<VideoCapturer> WebRtcVideoDeviceCapturerFactory::Create( |
+ const Device& device) { |
#ifdef HAVE_WEBRTC_VIDEO |
std::unique_ptr<WebRtcVideoCapturer> capturer( |
new WebRtcVideoCapturer()); |
if (!capturer->Init(device)) { |
- return nullptr; |
+ return std::unique_ptr<VideoCapturer>(); |
} |
- return capturer.release(); |
+ return std::move(capturer); |
#else |
- return nullptr; |
+ return std::unique_ptr<VideoCapturer>(); |
#endif |
} |