This is an automated email from the ASF dual-hosted git repository.
reta pushed a commit to branch 3.5.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git
The following commit(s) were added to refs/heads/3.5.x-fixes by this push:
new 15f81404a5 Fixing compilation issues (post CXF-8698 merge)
15f81404a5 is described below
commit 15f81404a531b9072854c417a5c0720dcbdc4684
Author: Andriy Redko <[email protected]>
AuthorDate: Sun Sep 18 15:38:16 2022 -0400
Fixing compilation issues (post CXF-8698 merge)
---
.../main/java/org/apache/cxf/attachment/AttachmentSerializer.java | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git
a/core/src/main/java/org/apache/cxf/attachment/AttachmentSerializer.java
b/core/src/main/java/org/apache/cxf/attachment/AttachmentSerializer.java
index bb3dc4e04d..6f92afa946 100644
--- a/core/src/main/java/org/apache/cxf/attachment/AttachmentSerializer.java
+++ b/core/src/main/java/org/apache/cxf/attachment/AttachmentSerializer.java
@@ -23,6 +23,7 @@ import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.StringWriter;
+import java.io.UnsupportedEncodingException;
import java.io.Writer;
import java.net.URLDecoder;
import java.net.URLEncoder;
@@ -374,7 +375,7 @@ public class AttachmentSerializer {
// URL decoder would also decode '+' but according to RFC-2392 we need to
convert
// only the % encoded character to their equivalent US-ASCII characters.
- private static String decode(String s, Charset charset) {
- return URLDecoder.decode(s.replaceAll("([^%])[+]", "$1%2B"), charset);
+ private static String decode(String s, Charset charset) throws
UnsupportedEncodingException {
+ return URLDecoder.decode(s.replaceAll("([^%])[+]", "$1%2B"),
charset.name());
}
}