summaryrefslogtreecommitdiff
path: root/fpdfsdk/src/javascript/JS_GlobalData.cpp
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2015-06-09 11:30:25 -0700
committerTom Sepez <tsepez@chromium.org>2015-06-09 11:30:25 -0700
commitbb17868d736f698d5217c30d52c5bbfed62c5936 (patch)
tree9d4d3e2538a81e6241d4992570bc3f3c1af71d28 /fpdfsdk/src/javascript/JS_GlobalData.cpp
parentbf6c2a4873f8cc12ad910fb904218a78087a3735 (diff)
downloadpdfium-bb17868d736f698d5217c30d52c5bbfed62c5936.tar.xz
Use stdint.h types throughout PDFium.
It's redundant nowadays to provide our own equivalents, now that this is done for us by the system header. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1177483002
Diffstat (limited to 'fpdfsdk/src/javascript/JS_GlobalData.cpp')
-rw-r--r--fpdfsdk/src/javascript/JS_GlobalData.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/fpdfsdk/src/javascript/JS_GlobalData.cpp b/fpdfsdk/src/javascript/JS_GlobalData.cpp
index b4e4a5b108..450c7a1338 100644
--- a/fpdfsdk/src/javascript/JS_GlobalData.cpp
+++ b/fpdfsdk/src/javascript/JS_GlobalData.cpp
@@ -105,7 +105,7 @@ void CJS_GlobalVariableArray::Empty()
#define PHANTOM_JS_GLOBALDATA_FILENAME L"Phantom_JsGlobal.Data"
#define SDK_JS_GLOBALDATA_FILENAME L"SDK_JsGlobal.Data"
-static const FX_BYTE JS_RC4KEY[] = {0x19,0xa8,0xe8,0x01,0xf6,0xa8,0xb6,0x4d,0x82,0x04,
+static const uint8_t JS_RC4KEY[] = {0x19,0xa8,0xe8,0x01,0xf6,0xa8,0xb6,0x4d,0x82,0x04,
0x45,0x6d,0xb4,0xcf,0xd7,0x77,0x67,0xf9,0x75,0x9f,
0xf0,0xe0,0x1e,0x51,0xee,0x46,0xfd,0x0b,0xc9,0x93,
0x25,0x55,0x4a,0xee,0xe0,0x16,0xd0,0xdf,0x8c,0xfa,
@@ -338,7 +338,7 @@ FX_BOOL CJS_GlobalData::DeleteGlobalVariable(FX_LPCSTR propname)
return FALSE;
}
-FX_INT32 CJS_GlobalData::GetSize() const
+int32_t CJS_GlobalData::GetSize() const
{
return m_arrayGlobalData.GetSize();
}
@@ -351,7 +351,7 @@ CJS_GlobalData_Element* CJS_GlobalData::GetAt(int index) const
void CJS_GlobalData::LoadGlobalPersistentVariables()
{
FX_LPBYTE pBuffer = NULL;
- FX_INT32 nLength = 0;
+ int32_t nLength = 0;
LoadFileBuffer(m_sFilePath.c_str(), pBuffer, nLength);
CRYPT_ArcFourCryptBlock(pBuffer, nLength, JS_RC4KEY, sizeof(JS_RC4KEY));
@@ -379,7 +379,7 @@ void CJS_GlobalData::LoadGlobalPersistentVariables()
if (dwSize == nLength - sizeof(FX_WORD) * 2 - sizeof(FX_DWORD)* 2)
{
- for (FX_INT32 i=0,sz=dwCount; i<sz; i++)
+ for (int32_t i=0,sz=dwCount; i<sz; i++)
{
if (p > pBuffer + nLength)
break;
@@ -511,12 +511,12 @@ void CJS_GlobalData::SaveGlobalPersisitentVariables()
WriteFileBuffer(m_sFilePath.c_str(), (FX_LPCSTR)sFile.GetBuffer(), sFile.GetSize());
}
-void CJS_GlobalData::LoadFileBuffer(FX_LPCWSTR sFilePath, FX_LPBYTE& pBuffer, FX_INT32& nLength)
+void CJS_GlobalData::LoadFileBuffer(FX_LPCWSTR sFilePath, FX_LPBYTE& pBuffer, int32_t& nLength)
{
//UnSupport.
}
-void CJS_GlobalData::WriteFileBuffer(FX_LPCWSTR sFilePath, FX_LPCSTR pBuffer, FX_INT32 nLength)
+void CJS_GlobalData::WriteFileBuffer(FX_LPCWSTR sFilePath, FX_LPCSTR pBuffer, int32_t nLength)
{
//UnSupport.
}