Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(175)

Unified Diff: xfa/fgas/crt/fgas_codepage.cpp

Issue 2095653002: Remove NULL in xfa/ (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Rebase to master Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « xfa/fde/fde_gedevice.cpp ('k') | xfa/fgas/crt/fgas_stream.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fgas/crt/fgas_codepage.cpp
diff --git a/xfa/fgas/crt/fgas_codepage.cpp b/xfa/fgas/crt/fgas_codepage.cpp
index 2087cac1384169c74bf04f8982f76237614fea31..834056eddd5004c8606eeba39c10d0b27b8610d5 100644
--- a/xfa/fgas/crt/fgas_codepage.cpp
+++ b/xfa/fgas/crt/fgas_codepage.cpp
@@ -272,7 +272,7 @@ const FX_STR2CPHASH g_FXCPHashTable[] = {
};
uint16_t GetCodePageFromStringA(const FX_CHAR* pStr, int32_t iLength) {
- ASSERT(pStr != NULL);
+ ASSERT(pStr);
if (iLength < 0) {
iLength = FXSYS_strlen(pStr);
}
@@ -370,7 +370,7 @@ uint16_t FX_GetCodePageFromStringW(const FX_WCHAR* pStr, int32_t iLength) {
}
void FX_SwapByteOrder(FX_WCHAR* pStr, int32_t iLength) {
- ASSERT(pStr != NULL);
+ ASSERT(pStr);
if (iLength < 0) {
iLength = FXSYS_wcslen(pStr);
}
@@ -392,7 +392,7 @@ void FX_SwapByteOrder(FX_WCHAR* pStr, int32_t iLength) {
}
void FX_UTF16ToWChar(void* pBuffer, int32_t iLength) {
- ASSERT(pBuffer != NULL && iLength > 0);
+ ASSERT(pBuffer && iLength > 0);
if (sizeof(FX_WCHAR) == 2) {
return;
}
@@ -404,7 +404,7 @@ void FX_UTF16ToWChar(void* pBuffer, int32_t iLength) {
}
void FX_WCharToUTF16(void* pBuffer, int32_t iLength) {
- ASSERT(pBuffer != NULL && iLength > 0);
+ ASSERT(pBuffer && iLength > 0);
if (sizeof(FX_WCHAR) == 2) {
return;
}
@@ -430,7 +430,7 @@ int32_t FX_UTF8Decode(const FX_CHAR* pSrc,
int32_t* pSrcLen,
FX_WCHAR* pDst,
int32_t* pDstLen) {
- if (pSrcLen == NULL || pDstLen == NULL) {
+ if (!pSrcLen || !pDstLen) {
return -1;
}
int32_t iSrcLen = *pSrcLen;
@@ -439,7 +439,7 @@ int32_t FX_UTF8Decode(const FX_CHAR* pSrc,
return 1;
}
int32_t iDstLen = *pDstLen;
- FX_BOOL bValidDst = (pDst != NULL && iDstLen > 0);
+ FX_BOOL bValidDst = (pDst && iDstLen > 0);
uint32_t dwCode = 0;
int32_t iPending = 0;
int32_t iSrcNum = 0, iDstNum = 0;
« no previous file with comments | « xfa/fde/fde_gedevice.cpp ('k') | xfa/fgas/crt/fgas_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698