File: 01-servlet-api-compatibility.patch

package info (click to toggle)
oscache 2.4.1%2Bds1-7
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, buster, sid, trixie
  • size: 2,576 kB
  • sloc: java: 9,018; xml: 1,237; jsp: 574; makefile: 4
file content (31 lines) | stat: -rw-r--r-- 1,055 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
Description: Fix the compatibility with the latest version of the Servlet API
Author: Emmanuel Bourg <ebourg@apache.org>
Forwarded: no
--- a/src/java/com/opensymphony/oscache/web/filter/SplitServletOutputStream.java
+++ b/src/java/com/opensymphony/oscache/web/filter/SplitServletOutputStream.java
@@ -91,4 +91,9 @@
         passThroughStream.close();
     }    
 
+    public void setWriteListener(javax.servlet.WriteListener writeListener) { }
+
+    public boolean isReady() {
+        return true;
+    }
 }
--- a/pom.xml
+++ b/pom.xml
@@ -271,6 +271,13 @@
             <groupId>javax.servlet</groupId>
             <artifactId>servlet-api</artifactId>
             <version>2.3</version>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>javax.servlet.jsp</groupId>
+            <artifactId>javax.servlet.jsp-api</artifactId>
+            <version>2.3</version>
+            <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>jgroups</groupId>