[vlc-devel] commit: Turn comment into error message. (Jean-Paul Saman )

git version control git at videolan.org
Sat Jun 14 11:05:51 CEST 2008


vlc | branch: master | Jean-Paul Saman <jpsaman at videolan.org> | Sat Jun 14 11:05:32 2008 +0200| [0ac31c77f2e46da5bc61cb3dcdc77651ecf43027]

Turn comment into error message.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=0ac31c77f2e46da5bc61cb3dcdc77651ecf43027
---

 projects/activex/vlccontrol.cpp |   24 ++++++++++++++++++------
 1 files changed, 18 insertions(+), 6 deletions(-)

diff --git a/projects/activex/vlccontrol.cpp b/projects/activex/vlccontrol.cpp
index 45347f7..298a449 100644
--- a/projects/activex/vlccontrol.cpp
+++ b/projects/activex/vlccontrol.cpp
@@ -509,16 +509,28 @@ STDMETHODIMP VLCControl::toggleMute(void)
 
 STDMETHODIMP VLCControl::setVariable(BSTR name, VARIANT value)
 {
-    /** setVariable() is an unsafe interface because of security
-      implications it has and is thus removed. */
-    return E_INVALIDARG;
+    libvlc_instance_t* p_libvlc;
+    HRESULT result = _p_instance->getVLC(&p_libvlc);
+    if( SUCCEEDED(result) )
+    {
+        _p_instance->setErrorInfo(IID_IVLCControl,
+            "setVariable() is an unsafe interface to use. "
+            "It has been removed because of security implications." );
+    }
+    return E_FAIL;
 };
 
 STDMETHODIMP VLCControl::getVariable(BSTR name, VARIANT *value)
 {
-    /** getVariable() is an unsafe interface because of security
-      implications it has and is thus removed. */
-    return E_INVALIDARG;
+    libvlc_instance_t* p_libvlc;
+    HRESULT result = _p_instance->getVLC(&p_libvlc);
+    if( SUCCEEDED(result) )
+    {
+        _p_instance->setErrorInfo(IID_IVLCControl,
+            "getVariable() is an unsafe interface to use. "
+            "It has been removed because of security implications." );
+    }
+    return E_FAIL;
 };
 
 void VLCControl::FreeTargetOptions(char **cOptions, int cOptionCount)




More information about the vlc-devel mailing list