summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Lillqvist <tml@collabora.com>2015-02-23 14:42:08 +0200
committerAndras Timar <andras.timar@collabora.com>2015-03-05 15:23:19 +0100
commit8215f8b4d3a3d2e04355bc4608f55d768eb8ebd2 (patch)
tree0984695f603f5a93349c07fd8eae359d6b58437e
parent97917a810b60781314efdb6fac39fd6b8fb9671a (diff)
tdf#84881: Unclear what the PKIStatusInfo::statusString is
Anyway, we can't assume that a string from an external source is correctly formed UTF-8. Change-Id: Ic906c7047b933388d5b51b23095a5a3d4ac7e508 (cherry picked from commit 639730a75294346d4195539c26f466f14d030802)
-rw-r--r--vcl/source/gdi/pdfwriter_impl.cxx10
1 files changed, 6 insertions, 4 deletions
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx
index bcc96bad2f9e..e0fb89a68498 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -6349,10 +6349,12 @@ OUString PKIStatusInfoToString(const PKIStatusInfo& rStatusInfo)
result += PKIStatusToString(rStatusInfo.status.data[0]);
else
result += "unknown (len=" + OUString::number(rStatusInfo.status.len);
- if (rStatusInfo.statusString.data != NULL)
- result += ",statusString='" +
- OUString::fromUtf8(OString(reinterpret_cast<const sal_Char*>(rStatusInfo.statusString.data), rStatusInfo.statusString.len)) +
- "'";
+
+ // FIXME: Perhaps look at rStatusInfo.statusString.data but note
+ // that we of course can't assume it contains proper UTF-8. After
+ // all, it is data from an external source. Also, RFC3161 claims
+ // it should be a SEQUENCE (1..MAX) OF UTF8String, but another
+ // source claimed it would be a single UTF8String, hmm?
// FIXME: Worth it to decode failInfo to cleartext, probably not at least as long as this is only for a SAL_INFO