You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mod_python-commits@quetz.apache.org by gr...@apache.org on 2006/11/23 01:08:37 UTC

svn commit: r478403 - in /httpd/mod_python/trunk: lib/python/mod_python/__init__.py src/_apachemodule.c src/include/mpversion.h

Author: grahamd
Date: Wed Nov 22 16:08:36 2006
New Revision: 478403

URL: http://svn.apache.org/viewvc?view=rev&rev=478403
Log:
(MODPYTHON-128) The apache.stat() function, which is a wrapper for the
apr_stat() function, should still return a valid finfoobject when the
target of the apr_stat() call does not exist. This is instead of raising
an exception. This is necessary as otherwise there is no way of replacing
req.finfo with a finfoobject where req.finfo.filetype is APR_NOFILE. An
exception will only be raised now if a truly unexpected problem arises.
Callers of apache.stat() need to check finfo.filetype for APR_NOFILE if
they need to know if target existed or not.


Modified:
    httpd/mod_python/trunk/lib/python/mod_python/__init__.py
    httpd/mod_python/trunk/src/_apachemodule.c
    httpd/mod_python/trunk/src/include/mpversion.h

Modified: httpd/mod_python/trunk/lib/python/mod_python/__init__.py
URL: http://svn.apache.org/viewvc/httpd/mod_python/trunk/lib/python/mod_python/__init__.py?view=diff&rev=478403&r1=478402&r2=478403
==============================================================================
--- httpd/mod_python/trunk/lib/python/mod_python/__init__.py (original)
+++ httpd/mod_python/trunk/lib/python/mod_python/__init__.py Wed Nov 22 16:08:36 2006
@@ -20,5 +20,5 @@
 __all__ = ["apache", "cgihandler", "psp",
            "publisher", "util", "python22"]
 
-version = "3.3.0-dev-20061122"
+version = "3.3.0-dev-20061123"
 

Modified: httpd/mod_python/trunk/src/_apachemodule.c
URL: http://svn.apache.org/viewvc/httpd/mod_python/trunk/src/_apachemodule.c?view=diff&rev=478403&r1=478402&r2=478403
==============================================================================
--- httpd/mod_python/trunk/src/_apachemodule.c (original)
+++ httpd/mod_python/trunk/src/_apachemodule.c Wed Nov 22 16:08:36 2006
@@ -728,6 +728,9 @@
     if (result == APR_INCOMPLETE || result == APR_SUCCESS)
         return (PyObject *)finfo;
 
+    if (result == APR_ENOENT)
+        return (PyObject *)finfo;
+
     Py_DECREF(finfo);
 
     PyErr_SetObject(PyExc_OSError,

Modified: httpd/mod_python/trunk/src/include/mpversion.h
URL: http://svn.apache.org/viewvc/httpd/mod_python/trunk/src/include/mpversion.h?view=diff&rev=478403&r1=478402&r2=478403
==============================================================================
--- httpd/mod_python/trunk/src/include/mpversion.h (original)
+++ httpd/mod_python/trunk/src/include/mpversion.h Wed Nov 22 16:08:36 2006
@@ -1,5 +1,5 @@
 #define MPV_MAJOR 3
 #define MPV_MINOR 3
 #define MPV_PATCH 0
-#define MPV_BUILD 20061122
-#define MPV_STRING "3.3.0-dev-20061122"
+#define MPV_BUILD 20061123
+#define MPV_STRING "3.3.0-dev-20061123"