Fix build error in ppapi_decryptor.cc

We were getting the following build error on Windows:

    FAILED: ninja -t msvc -o obj\webkit\media\crypto\webkit_media.ppapi_decryptor.obj -e environment.x86 -- cl.exe /nologo /showIncludes /FC @obj\webkit\media\crypto\webkit_media.ppapi_decryptor.obj.rsp /c ..\..\webkit\media\crypto\ppapi_decryptor.cc /Foobj\webkit\media\crypto\webkit_media.ppapi_decryptor.obj /Fdobj\webkit\support\webkit_media.pdb
    vendor\chromium\src\base\memory\ref_counted.h(250) : error C2027: use of undefined type 'webkit::ppapi::PPB_Buffer_Impl'

            vendor\chromium\src\webkit\plugins\ppapi\content_decryptor_delegate.h(30) : see declaration of 'webkit::ppapi::PPB_Buffer_Impl'

            vendor\chromium\src\base\memory\ref_counted.h(248) : while compiling class template member function 'scoped_refptr<T>::~scoped_refptr(void)'

            with

            [

                T=webkit::ppapi::PPB_Buffer_Impl

            ]

            vendor\chromium\src\webkit\plugins\ppapi\content_decryptor_delegate.h(163) : see reference to class template instantiation 'scoped_refptr<T>' being compiled

            with

            [

                T=webkit::ppapi::PPB_Buffer_Impl

            ]

    vendor\chromium\src\base\memory\ref_counted.h(250) : error C2227: left of '->Release' must point to class/struct/union/generic type

I believe something about our __declspec(dllexport) declarations is
causing this to happen. We work around this by defining an out-of-line
destructor for ContentDecryptorDelegate so ppapi_decryptor.cc doesn't
have to compile its destructor.
This commit is contained in:
Adam Roben 2013-05-13 12:21:23 -04:00
Родитель d4cefbe638
Коммит d2b38146b8
1 изменённых файлов: 26 добавлений и 0 удалений

Просмотреть файл

@ -0,0 +1,26 @@
Index: webkit/plugins/ppapi/content_decryptor_delegate.cc
===================================================================
--- webkit/plugins/ppapi/content_decryptor_delegate.cc (revision 194718)
+++ webkit/plugins/ppapi/content_decryptor_delegate.cc (working copy)
@@ -285,6 +285,9 @@
weak_this_(weak_ptr_factory_.GetWeakPtr()) {
}
+ContentDecryptorDelegate::~ContentDecryptorDelegate() {
+}
+
void ContentDecryptorDelegate::SetKeyEventCallbacks(
const media::KeyAddedCB& key_added_cb,
const media::KeyErrorCB& key_error_cb,
Index: webkit/plugins/ppapi/content_decryptor_delegate.h
===================================================================
--- webkit/plugins/ppapi/content_decryptor_delegate.h (revision 194718)
+++ webkit/plugins/ppapi/content_decryptor_delegate.h (working copy)
@@ -37,6 +37,7 @@
ContentDecryptorDelegate(
PP_Instance pp_instance,
const PPP_ContentDecryptor_Private* plugin_decryption_interface);
+ ~ContentDecryptorDelegate();
void SetKeyEventCallbacks(const media::KeyAddedCB& key_added_cb,
const media::KeyErrorCB& key_error_cb,