Christian Costa : mciqtz32: Make sure the device is valid before starting the play.

Alexandre Julliard julliard at winehq.org
Thu Apr 23 11:27:22 CDT 2009


Module: wine
Branch: master
Commit: 7b1b498a31283558523ccc12f735d85299756bdc
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=7b1b498a31283558523ccc12f735d85299756bdc

Author: Christian Costa <titan.costa at wanadoo.fr>
Date:   Thu Apr 23 00:03:58 2009 +0200

mciqtz32: Make sure the device is valid before starting the play.

---

 dlls/mciqtz32/mciqtz.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/dlls/mciqtz32/mciqtz.c b/dlls/mciqtz32/mciqtz.c
index 8222199..07b774c 100644
--- a/dlls/mciqtz32/mciqtz.c
+++ b/dlls/mciqtz32/mciqtz.c
@@ -241,6 +241,8 @@ static DWORD MCIQTZ_mciPlay(UINT wDevID, DWORD dwFlags, LPMCI_PLAY_PARMS lpParms
         return MCIERR_NULL_PARAMETER_BLOCK;
 
     wma = MCIQTZ_mciGetOpenDev(wDevID);
+    if (!wma)
+        return MCIERR_INVALID_DEVICE_ID;
 
     hr = IMediaControl_Run(wma->pmctrl);
     if (FAILED(hr)) {




More information about the wine-cvs mailing list