[libdvdcss-devel] [PATCH] win32: Remove unnecessary PATH_MAX definition

Diego Biurrun diego at biurrun.de
Mon Nov 3 11:09:42 CET 2014


PATH_MAX is present in all supported Windows platforms nowadays.
---
 src/common.h    | 4 ----
 src/libdvdcss.c | 2 +-
 2 files changed, 1 insertion(+), 5 deletions(-)

diff --git a/src/common.h b/src/common.h
index 99cb047..259477b 100644
--- a/src/common.h
+++ b/src/common.h
@@ -44,10 +44,6 @@
 #if defined( WIN32 )
 #   include <io.h>                                             /* _lseeki64 */
 
-#   ifndef PATH_MAX
-#      define PATH_MAX MAX_PATH
-#   endif
-
 /* several type definitions */
 #   if defined( __MINGW32__ )
 #       undef lseek
diff --git a/src/libdvdcss.c b/src/libdvdcss.c
index a380b8b..73c53e7 100644
--- a/src/libdvdcss.c
+++ b/src/libdvdcss.c
@@ -189,7 +189,7 @@ static char *set_cache_directory( struct dvdcss *dvdcss )
     if( psz_cache == NULL || psz_cache[0] == '\0' )
     {
 #if defined(_WIN32_IE) && _WIN32_IE >= 0x500
-        char psz_home[MAX_PATH];
+        char psz_home[PATH_MAX];
 
         /* Cache our keys in
          * C:\Documents and Settings\$USER\Application Data\dvdcss\ */
-- 
1.9.1



More information about the libdvdcss-devel mailing list