summaryrefslogtreecommitdiff
path: root/core/src
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2015-11-02 14:20:08 -0500
committerDan Sinclair <dsinclair@chromium.org>2015-11-02 14:20:08 -0500
commite65be3a55628294d0f45da456d856b4539f0cb15 (patch)
tree251768311e5db098b864be2ad4060c10071a43cb /core/src
parent52b0b525dca3d982a04b77fa6d0913aff1e5fd9c (diff)
downloadpdfium-e65be3a55628294d0f45da456d856b4539f0cb15.tar.xz
Remove _FPDF_ByteStringFromHex as it is unused
There are no uses of this method, I also checked the XFA branch and there don't appear to be any uses there either. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1427913006 .
Diffstat (limited to 'core/src')
-rw-r--r--core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp39
1 files changed, 0 insertions, 39 deletions
diff --git a/core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp b/core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp
index 3057948959..e095414ffe 100644
--- a/core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp
+++ b/core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp
@@ -1532,42 +1532,3 @@ void CPDF_StreamContentParser::AddPathObject(int FillType, FX_BOOL bStroke) {
m_pCurStates->m_ClipPath.AppendPath(Path, PathClipType, TRUE);
}
}
-CFX_ByteString _FPDF_ByteStringFromHex(CFX_BinaryBuf& src_buf) {
- CFX_ByteTextBuf buf;
- FX_BOOL bFirst = TRUE;
- int code = 0;
- const uint8_t* str = src_buf.GetBuffer();
- FX_DWORD size = src_buf.GetSize();
- for (FX_DWORD i = 0; i < size; i++) {
- uint8_t ch = str[i];
- if (ch >= '0' && ch <= '9') {
- if (bFirst) {
- code = (ch - '0') * 16;
- } else {
- code += ch - '0';
- buf.AppendChar((char)code);
- }
- bFirst = !bFirst;
- } else if (ch >= 'A' && ch <= 'F') {
- if (bFirst) {
- code = (ch - 'A' + 10) * 16;
- } else {
- code += ch - 'A' + 10;
- buf.AppendChar((char)code);
- }
- bFirst = !bFirst;
- } else if (ch >= 'a' && ch <= 'f') {
- if (bFirst) {
- code = (ch - 'a' + 10) * 16;
- } else {
- code += ch - 'a' + 10;
- buf.AppendChar((char)code);
- }
- bFirst = !bFirst;
- }
- }
- if (!bFirst) {
- buf.AppendChar((char)code);
- }
- return buf.GetByteString();
-}