X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=activex%2Fpersistpropbag.h;h=f4e081c65ed61623744103fc66924255db515b4f;hb=a46cc88f28f7853368ca68841a865d55a73aa520;hp=2a69690581d2304737e62d0b72da25ec9bfec471;hpb=35db6dd6ecab2daf4c03ccc2c0be4b25a42c092c;p=vlc diff --git a/activex/persistpropbag.h b/activex/persistpropbag.h index 2a69690581..f4e081c65e 100644 --- a/activex/persistpropbag.h +++ b/activex/persistpropbag.h @@ -17,7 +17,7 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA. *****************************************************************************/ #ifndef __PERSISTPROPBAG_H__ @@ -36,10 +36,12 @@ public: // IUnknown methods STDMETHODIMP QueryInterface(REFIID riid, void **ppv) { - if( (NULL != ppv) - && (IID_IUnknown == riid) - && (IID_IPersist == riid) - && (IID_IPersistPropertyBag == riid) ) { + if( NULL == ppv ) + return E_POINTER; + if( (IID_IUnknown == riid) + || (IID_IPersist == riid) + || (IID_IPersistPropertyBag == riid) ) + { AddRef(); *ppv = reinterpret_cast(this); return NOERROR;