[libdvdcss-devel] ioctl: Initialize variable before use in ioctl_ReportAgid()

Diego Biurrun git at videolan.org
Thu Oct 30 17:16:34 CET 2014


libdvdcss | branch: master | Diego Biurrun <diego at biurrun.de> | Tue Oct 28 18:05:47 2014 +0100| [665cacf448bfc9f5f3c81e5a37fa2c533071b418] | committer: Diego Biurrun

ioctl: Initialize variable before use in ioctl_ReportAgid()

This silences a complaint from the MSVC code analyzer.

> http://git.videolan.org/gitweb.cgi/libdvdcss.git/?a=commit;h=665cacf448bfc9f5f3c81e5a37fa2c533071b418
---

 src/ioctl.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/ioctl.c b/src/ioctl.c
index 063e1c4..696588e 100644
--- a/src/ioctl.c
+++ b/src/ioctl.c
@@ -616,7 +616,7 @@ int ioctl_ReportAgid( int i_fd, int *pi_agid )
     if( WIN2K ) /* NT/2k/XP */
     {
         ULONG id;
-        DWORD tmp;
+        DWORD tmp = 0;
 
         i_ret = DeviceIoControl( (HANDLE) i_fd, IOCTL_DVD_START_SESSION,
                         &tmp, 4, &id, sizeof( id ), &tmp, NULL ) ? 0 : -1;



More information about the libdvdcss-devel mailing list