From ea72c34fb9bb000b86dce1cc69c59af895f709aa Mon Sep 17 00:00:00 2001 From: "perkj@google.com" Date: Mon, 5 Sep 2011 11:11:04 +0000 Subject: [PATCH] Temporary add dummy implementation to RefCountModule. The reason is so that ADM and VideoCapture implementations can change to refcounted versions before forcing them. Review URL: http://webrtc-codereview.appspot.com/139014 git-svn-id: http://webrtc.googlecode.com/svn/trunk@527 4adac7df-926f-26a2-2b94-8c16560cd09d --- src/modules/interface/module.h | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/src/modules/interface/module.h b/src/modules/interface/module.h index 0a74f2a951..29ad0c3c58 100644 --- a/src/modules/interface/module.h +++ b/src/modules/interface/module.h @@ -11,6 +11,8 @@ #ifndef MODULES_INTERFACE_MODULE_H_ #define MODULES_INTERFACE_MODULE_H_ +#include + #include "typedefs.h" namespace webrtc { @@ -41,13 +43,23 @@ class RefCountedModule : public Module { public: // Increase the reference count by one. // Returns the incremented reference count. - virtual int32_t AddRef() = 0; + // TODO(perkj): Make this pure virtual when Chromium have implemented + // reference counting ADM and Video capture module. + virtual int32_t AddRef() { + assert("Not implemented."); + return 1; + } // Decrease the reference count by one. // Returns the decreased reference count. // Returns 0 if the last reference was just released. // When the reference count reach 0 the object will self-destruct. - virtual int32_t Release() = 0; + // TODO(perkj): Make this pure virtual when Chromium have implemented + // reference counting ADM and Video capture module. + virtual int32_t Release() { + assert("Not implemented."); + return 1; + } protected: virtual ~RefCountedModule() {}