]> granicus.if.org Git - php/commitdiff
removed now obsolete NetWare hack since I fixed this
authorGuenter Knauf <guenter@php.net>
Tue, 3 Nov 2009 21:21:34 +0000 (21:21 +0000)
committerGuenter Knauf <guenter@php.net>
Tue, 3 Nov 2009 21:21:34 +0000 (21:21 +0000)
with Novell some longer time ago in their SDK header.

ext/exif/exif.c
ext/session/mod_files.c
ext/session/session.c
ext/standard/file.c
ext/standard/filestat.c
ext/standard/ftp_fopen_wrapper.c
ext/standard/pageinfo.c

index 13989faaaaa0b0e3ce56f62adf02da4633835238..c3d3c328ded401a3e96368d1e50674a8e6fba7f5 100644 (file)
@@ -3854,11 +3854,7 @@ static int exif_read_file(image_info_type *ImageInfo, char *FileName, int read_t
                        }
 
                        /* Store file date/time. */
-#ifdef NETWARE
-                       ImageInfo->FileDateTime = st.st_mtime.tv_sec;
-#else
                        ImageInfo->FileDateTime = st.st_mtime;
-#endif
                        ImageInfo->FileSize = st.st_size;
                        /*exif_error_docref(NULL EXIFERR_CC, ImageInfo, E_NOTICE, "Opened stream is file: %d", ImageInfo->FileSize);*/
                }
index 1459067850a7e3b0af99c7c715e1b03deb399472..6e996bf0175646b27db33438953a1c04c415cafd 100644 (file)
@@ -263,11 +263,7 @@ static int ps_files_cleanup_dir(const char *dirname, int maxlifetime TSRMLS_DC)
 
                                /* check whether its last access was more than maxlifet ago */
                                if (VCWD_STAT(buf, &sbuf) == 0 &&
-#ifdef NETWARE
-                                               (now - sbuf.st_mtime.tv_sec) > maxlifetime) {
-#else
                                                (now - sbuf.st_mtime) > maxlifetime) {
-#endif
                                        VCWD_UNLINK(buf);
                                        nrdels++;
                                }
index c03e3ade1cec3663ac0658cfc177a4d4b4912786..c0d6691734b020b1e153abb4292f4b3b60fe627a 100644 (file)
@@ -66,12 +66,6 @@ static int php_session_rfc1867_callback(unsigned int event, void *event_data, vo
    * Helpers *
    *********** */
 
-#ifdef NETWARE
-# define SESS_SB_MTIME(sb)     ((sb).st_mtime.tv_sec)
-#else
-# define SESS_SB_MTIME(sb)     ((sb).st_mtime)
-#endif
-
 #define IF_SESSION_VARS() \
        if (PS(http_session_vars) && PS(http_session_vars)->type == IS_ARRAY)
 
@@ -1016,7 +1010,7 @@ static inline void last_modified(TSRMLS_D) /* {{{ */
 
 #define LAST_MODIFIED "Last-Modified: "
                memcpy(buf, LAST_MODIFIED, sizeof(LAST_MODIFIED) - 1);
-               strcpy_gmt(buf + sizeof(LAST_MODIFIED) - 1, &SESS_SB_MTIME(sb));
+               strcpy_gmt(buf + sizeof(LAST_MODIFIED) - 1, &sb.st_mtime);
                ADD_HEADER(buf);
        }
 }
index fb3c71f6ca6f0413eae3918ef0cc6295216cdaf1..1e2bd6c097c52ce4a3d9dc5e7e007e1275383094 100644 (file)
 # include "win32/param.h"
 # include "win32/winutil.h"
 # include "win32/fnmatch.h"
-#elif defined(NETWARE)
-# include <sys/param.h>
-# include <sys/select.h>
-# ifdef USE_WINSOCK
-#  include <novsock2.h>
-# else
-#  include <sys/socket.h>
-#  include <netinet/in.h>
-#  include <netdb.h>
-# endif
 #else
 # if HAVE_SYS_PARAM_H
 #  include <sys/param.h>
@@ -1811,16 +1801,9 @@ PHP_NAMED_FUNCTION(php_if_fstat)
        MAKE_LONG_ZVAL_INCREF(stat_rdev, -1);
 #endif
        MAKE_LONG_ZVAL_INCREF(stat_size, stat_ssb.sb.st_size);
-#ifdef NETWARE
-       MAKE_LONG_ZVAL_INCREF(stat_atime, stat_ssb.sb.st_atime.tv_sec);
-       MAKE_LONG_ZVAL_INCREF(stat_mtime, stat_ssb.sb.st_mtime.tv_sec);
-       MAKE_LONG_ZVAL_INCREF(stat_ctime, stat_ssb.sb.st_ctime.tv_sec);
-#else
        MAKE_LONG_ZVAL_INCREF(stat_atime, stat_ssb.sb.st_atime);
        MAKE_LONG_ZVAL_INCREF(stat_mtime, stat_ssb.sb.st_mtime);
        MAKE_LONG_ZVAL_INCREF(stat_ctime, stat_ssb.sb.st_ctime);
-#endif
-
 #ifdef HAVE_ST_BLKSIZE
        MAKE_LONG_ZVAL_INCREF(stat_blksize, stat_ssb.sb.st_blksize);
 #else
index 15dd4af1be06b140f7fd95c8560cafe0b511bca2..37a8e54233eff9bdf86ccd18a821f819ce1250c4 100644 (file)
@@ -417,7 +417,7 @@ freespace_failure:
 }
 /* }}} */
 
-#if !defined(WINDOWS)
+#if !defined(WINDOWS) && !defined(NETWARE)
 static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */
 {
        char *filename;
@@ -538,7 +538,7 @@ PHP_FUNCTION(lchgrp)
 /* }}} */
 #endif /* !NETWARE */
 
-#if !defined(WINDOWS)
+#if !defined(WINDOWS) && !defined(NETWARE)
 static void php_do_chown(INTERNAL_FUNCTION_PARAMETERS, int do_lchown) /* {{{ */
 {
        char *filename;
@@ -985,23 +985,11 @@ PHPAPI void php_stat(const char *filename, php_stat_len filename_length, int typ
        case FS_GROUP:
                RETURN_LONG((long)ssb.sb.st_gid);
        case FS_ATIME:
-#ifdef NETWARE
-               RETURN_LONG((long)ssb.sb.st_atime.tv_sec);
-#else
                RETURN_LONG((long)ssb.sb.st_atime);
-#endif
        case FS_MTIME:
-#ifdef NETWARE
-               RETURN_LONG((long)ssb.sb.st_mtime.tv_sec);
-#else
                RETURN_LONG((long)ssb.sb.st_mtime);
-#endif
        case FS_CTIME:
-#ifdef NETWARE
-               RETURN_LONG((long)ssb.sb.st_ctime.tv_sec);
-#else
                RETURN_LONG((long)ssb.sb.st_ctime);
-#endif
        case FS_TYPE:
                if (S_ISLNK(ssb.sb.st_mode)) {
                        RETURN_ASCII_STRING("link", 1);
@@ -1049,15 +1037,9 @@ PHPAPI void php_stat(const char *filename, php_stat_len filename_length, int typ
                MAKE_LONG_ZVAL_INCREF(stat_rdev, -1);
 #endif
                MAKE_LONG_ZVAL_INCREF(stat_size, stat_sb->st_size);
-#ifdef NETWARE
-               MAKE_LONG_ZVAL_INCREF(stat_atime, (stat_sb->st_atime).tv_sec);
-               MAKE_LONG_ZVAL_INCREF(stat_mtime, (stat_sb->st_mtime).tv_sec);
-               MAKE_LONG_ZVAL_INCREF(stat_ctime, (stat_sb->st_ctime).tv_sec);
-#else
                MAKE_LONG_ZVAL_INCREF(stat_atime, stat_sb->st_atime);
                MAKE_LONG_ZVAL_INCREF(stat_mtime, stat_sb->st_mtime);
                MAKE_LONG_ZVAL_INCREF(stat_ctime, stat_sb->st_ctime);
-#endif
 #ifdef HAVE_ST_BLKSIZE
                MAKE_LONG_ZVAL_INCREF(stat_blksize, stat_sb->st_blksize);
 #else
index 544da90f56551f82ca4fa5a07df3855befb0c2b0..68e9b069c7a32ba0c1248c40516e76b79e353033 100644 (file)
@@ -835,32 +835,19 @@ static int php_stream_ftp_url_stat(php_stream_wrapper *wrapper, char *url, int f
                tm.tm_sec += stamp - mktime(gmt);
                tm.tm_isdst = gmt->tm_isdst;
 
-#ifdef NETWARE
-               ssb->sb.st_mtime.tv_sec = mktime(&tm);
-#else
                ssb->sb.st_mtime = mktime(&tm);
-#endif
        } else {
                /* error or unsupported command */
 mdtm_error:
-#ifdef NETWARE
-               ssb->sb.st_mtime.tv_sec = -1;
-#else
                ssb->sb.st_mtime = -1;
-#endif
        }
 
        ssb->sb.st_ino = 0;                                             /* Unknown values */
        ssb->sb.st_dev = 0;
        ssb->sb.st_uid = 0;
        ssb->sb.st_gid = 0;
-#ifdef NETWARE
-       ssb->sb.st_atime.tv_sec = -1;
-       ssb->sb.st_ctime.tv_sec = -1;
-#else
        ssb->sb.st_atime = -1;
        ssb->sb.st_ctime = -1;
-#endif
 
        ssb->sb.st_nlink = 1;
        ssb->sb.st_rdev = -1;
index 229e68393dbbcbb55266f3ea8ae04a4eae43c18b..5d6f52a396595aad99b091d0493f64fca344f074 100644 (file)
@@ -68,11 +68,7 @@ PHPAPI void php_statpage(TSRMLS_D)
                        BG(page_uid)   = pstat->st_uid;
                        BG(page_gid)   = pstat->st_gid;
                        BG(page_inode) = pstat->st_ino;
-#ifdef NETWARE
-                       BG(page_mtime) = (pstat->st_mtime).tv_sec;
-#else
                        BG(page_mtime) = pstat->st_mtime;
-#endif
                } else { /* handler for situations where there is no source file, ex. php -r */
                        BG(page_uid) = getuid();
                        BG(page_gid) = getgid();