Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
f11ee613
Commit
f11ee613
authored
Sep 19, 2002
by
Casey Duncan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Collector #574: Fixed write on HEAD requests caused by overzealous ETag support.
parent
3a24de4f
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
7 deletions
+10
-7
doc/CHANGES.txt
doc/CHANGES.txt
+2
-3
lib/python/webdav/EtagSupport.py
lib/python/webdav/EtagSupport.py
+4
-2
lib/python/webdav/Resource.py
lib/python/webdav/Resource.py
+4
-2
No files found.
doc/CHANGES.txt
View file @
f11ee613
...
...
@@ -6,9 +6,8 @@ Zope Changes
Bugs Fixed
- Fixed bug in manage_editProperties which used an incorrect default
for several types of property when they were not found in the
REQUEST.
- Collector #574: Fixed write on HEAD requests caused by overzealous
ETag support.
- Fixed broken management form for TopicIndexes.
...
...
lib/python/webdav/EtagSupport.py
View file @
f11ee613
...
...
@@ -11,7 +11,7 @@
#
##############################################################################
__version__
=
"$Revision: 1.
8
$"
[
11
:
-
2
]
__version__
=
"$Revision: 1.
9
$"
[
11
:
-
2
]
import
time
,
Interface
,
re
...
...
@@ -66,9 +66,11 @@ class EtagSupport:
"""
__implements__
=
(
EtagBaseInterface
,)
def
http__etag
(
self
):
def
http__etag
(
self
,
readonly
=
0
):
try
:
etag
=
self
.
__etag
except
AttributeError
:
if
readonly
:
# Don't refresh the etag on reads
return
self
.
http__refreshEtag
()
etag
=
self
.
__etag
return
etag
...
...
lib/python/webdav/Resource.py
View file @
f11ee613
...
...
@@ -13,7 +13,7 @@
"""WebDAV support - resource objects."""
__version__
=
'$Revision: 1.5
3
$'
[
11
:
-
2
]
__version__
=
'$Revision: 1.5
4
$'
[
11
:
-
2
]
import
sys
,
os
,
mimetypes
,
davcmds
,
ExtensionClass
,
Lockable
from
common
import
absattr
,
aq_base
,
urlfix
,
rfc1123_date
,
tokenFinder
,
urlbase
...
...
@@ -167,7 +167,9 @@ class Resource(ExtensionClass.Base, Lockable.LockableItem):
mtime
=
rfc1123_date
(
self
.
_p_mtime
)
RESPONSE
.
setHeader
(
'Last-Modified'
,
mtime
)
if
hasattr
(
aq_base
(
self
),
'http__etag'
):
RESPONSE
.
setHeader
(
'Etag'
,
self
.
aq_base
.
http__etag
())
etag
=
self
.
http__etag
(
readonly
=
1
)
if
etag
:
RESPONSE
.
setHeader
(
'Etag'
,
etag
)
RESPONSE
.
setStatus
(
200
)
return
RESPONSE
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment