ref: f35ad494d9fa93f079f6578ddd7d10ace0d8c617
parent: 143d07a2b017da4266c84b2c2b694519ab449dc2
author: Diego Biurrun <diego@biurrun.de>
date: Fri Oct 24 09:04:51 EDT 2014
Comment some #endifs for increased readability.
--- a/src/common.h
+++ b/src/common.h
@@ -62,7 +62,7 @@
# else
# define off_t long long
# endif
-# endif
+# endif /* defined( __MINGW32__ ) */
# if defined( _MSC_VER )
# define lseek _lseeki64
@@ -79,9 +79,9 @@
# define close _close
# define read _read
# define write _write
-# endif
+# endif /* defined( _MSC_VER ) */
-#endif
+#endif /* defined( WIN32 ) */
#ifdef __ANDROID__
# undef lseek
@@ -88,6 +88,6 @@
# define lseek lseek64
# undef off_t
# define off_t off64_t
-#endif
+#endif /* __ANDROID__ */
#endif /* DVDCSS_COMMON_H */
--- a/src/css.c
+++ b/src/css.c
@@ -122,7 +122,7 @@
i_copyright = 0;
}
}
-#endif
+#endif /* WIN32 */
if( i_ret < 0 )
{
@@ -1566,7 +1566,7 @@
{
b_stop_scanning = 1;
}
-#endif
+#endif /* 0 */
}
i_pos++;
@@ -1730,4 +1730,4 @@
return 0;
}
-#endif
+#endif /* 0 */
--- a/src/device.c
+++ b/src/device.c
@@ -408,7 +408,7 @@
return 0;
}
-#endif
+#endif /* DVDCSS_RAW_OPEN */
int dvdcss_close_device ( dvdcss_t dvdcss )
{
@@ -507,7 +507,7 @@
print_error( dvdcss, "failed opening device" );
return -1;
}
-#endif
+#endif /* defined( WIN32 ) */
#ifdef __OS2__
static int os2_open ( dvdcss_t dvdcss, const char *psz_device )
@@ -538,7 +538,7 @@
return 0;
}
-#endif
+#endif /* __OS2__ */
/*****************************************************************************
* Seek commands.
@@ -595,7 +595,7 @@
return dvdcss->i_pos;
}
-#endif
+#endif /* defined( WIN32 ) */
/*****************************************************************************
* Read commands.
@@ -650,7 +650,7 @@
dvdcss->i_pos += i_bytes / DVDCSS_BLOCK_SIZE;
return i_bytes / DVDCSS_BLOCK_SIZE;
}
-#endif
+#endif /* defined( WIN32 ) */
/*****************************************************************************
* Readv commands.
@@ -789,4 +789,4 @@
dvdcss->i_pos += i_blocks_read;
return i_blocks_read;
}
-#endif
+#endif /* defined( WIN32 ) */
--- a/src/ioctl.c
+++ b/src/ioctl.c
@@ -1479,7 +1479,7 @@
return ioctl( i_fd, USCSICMD, p_sc );
}
-#endif
+#endif /* defined( SOLARIS_USCSI ) */
#if defined( WIN32 )
/*****************************************************************************
@@ -1511,7 +1511,7 @@
p_sptd->TimeOutValue = 2;
}
-#endif
+#endif /* defined( WIN32 ) */
#if defined( __QNXNTO__ )
/*****************************************************************************
@@ -1542,7 +1542,7 @@
p_cpt->cam_timeout = CAM_TIME_DEFAULT;
}
-#endif
+#endif /* defined( __QNXNTO__ ) */
#if defined( __OS2__ )
/*****************************************************************************
@@ -1571,4 +1571,4 @@
p_sdc->id_code = 0x31304443; // 'CD01'
p_sdc->cmd_length = 12;
}
-#endif
+#endif /* defined( __OS2__ ) */
--- a/src/ioctl.h
+++ b/src/ioctl.h
@@ -286,7 +286,7 @@
UCHAR Cdb[16];
} SCSI_PASS_THROUGH_DIRECT, *PSCSI_PASS_THROUGH_DIRECT;
-#endif
+#endif /* defined( WIN32 ) */
/*****************************************************************************
* OS2 ioctl specific
@@ -312,6 +312,6 @@
#pragma pack()
-#endif
+#endif /* defined( __OS2__ ) */
#endif /* DVDCSS_IOCTL_H */
--- a/src/libdvdcss.c
+++ b/src/libdvdcss.c
@@ -240,7 +240,7 @@
}
#else
char *psz_home = NULL;
-# ifdef HAVE_PWD_H
+#ifdef HAVE_PWD_H
struct passwd *p_pwd;
/* Try looking in password file for home dir. */
@@ -249,7 +249,7 @@
{
psz_home = p_pwd->pw_dir;
}
-# endif
+#endif /* HAVE_PWD_H */
if( psz_home == NULL )
{
@@ -279,13 +279,13 @@
home_pos = 2;
}
}
-#endif
+#endif /* __OS2__ */
snprintf( psz_buffer + home_pos, PATH_MAX - home_pos,
"%s/.dvdcss", psz_home );
psz_buffer[PATH_MAX-1] = '\0';
psz_cache = psz_buffer;
}
-#endif
+#endif /* ! defined(_WIN32_IE) && _WIN32_IE >= 0x500 */
}
/*
@@ -514,7 +514,7 @@
{
dvdcss_raw_open( dvdcss, psz_raw_device );
}
-#endif
+#endif /* DVDCSS_RAW_OPEN */
/* Seek at the beginning, just for safety. */
dvdcss->pf_seek( dvdcss, 0 );
--- a/src/libdvdcss.h
+++ b/src/libdvdcss.h
@@ -70,7 +70,7 @@
int b_file;
char * p_readv_buffer;
int i_readv_buf_size;
-#endif
+#endif /* WIN32 */
#ifdef DVDCSS_RAW_OPEN
int i_raw_fd;