Commit 0790dd3a authored by Albert Astals Cid's avatar Albert Astals Cid

Fix missing-declarations warnings

... and add it to default warning set
parent afd91b14
......@@ -109,13 +109,13 @@ if(CMAKE_COMPILER_IS_GNUCXX)
set(_warn "${_warn} -Wmissing-format-attribute")
set(_warn "${_warn} -Wnon-virtual-dtor")
set(_warn "${_warn} -Woverloaded-virtual")
set(_warn "${_warn} -Wmissing-declarations")
if (NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "5.0.0")
set(_warn "${_warn} -Wsuggest-override")
endif()
# set extra warnings
set(_warnx "${_warnx} -Wconversion")
set(_warnx "${_warnx} -Wmissing-declarations")
set(_warnx "${_warnx} -Wshadow")
set(_warnx "${_warnx} -Wundef")
set(_warnx "${_warnx} -Wuseless-cast")
......
......@@ -85,7 +85,7 @@ static void error(const std::string &msg)
exit(1);
}
std::ostream& operator<<(std::ostream& stream, const poppler::ustring &str)
static std::ostream& operator<<(std::ostream& stream, const poppler::ustring &str)
{
const poppler::byte_array ba = str.to_utf8();
for (unsigned int i = 0; i < ba.size(); ++i) {
......
......@@ -229,6 +229,7 @@ poppler_action_copy (PopplerAction *action)
return new_action;
}
static
PopplerDest *
dest_new_goto (PopplerDocument *document,
LinkDest *link_dest)
......
......@@ -30,7 +30,7 @@ struct JpegWriterPrivate {
struct jpeg_error_mgr jerr;
};
void outputMessage(j_common_ptr cinfo)
static void outputMessage(j_common_ptr cinfo)
{
char buffer[JMSG_LENGTH_MAX];
......
......@@ -44,7 +44,7 @@ extern void *gmalloc_checkoverflow(size_t size);
* returns NULL. If <p> is NULL, calls malloc instead of realloc().
*/
extern void *grealloc(void *p, size_t size);
extern void *grealloc_checkoverflow(size_t size);
extern void *grealloc_checkoverflow(void *p, size_t size);
/*
* These are similar to gmalloc and grealloc, but take an object count
......
......@@ -113,7 +113,7 @@
// = (4 * (sqrt(2) - 1) / 3) * r
#define bezierCircle 0.55228475
AnnotLineEndingStyle parseAnnotLineEndingStyle(GooString *string) {
static AnnotLineEndingStyle parseAnnotLineEndingStyle(GooString *string) {
if (string != NULL) {
if (!string->cmp("Square")) {
return annotLineEndingSquare;
......@@ -141,7 +141,7 @@ AnnotLineEndingStyle parseAnnotLineEndingStyle(GooString *string) {
}
}
const char* convertAnnotLineEndingStyle(AnnotLineEndingStyle style) {
static const char* convertAnnotLineEndingStyle(AnnotLineEndingStyle style) {
switch (style) {
case annotLineEndingSquare:
return "Square";
......@@ -185,7 +185,7 @@ static AnnotExternalDataType parseAnnotExternalData(Dict* dict) {
return type;
}
PDFRectangle *parseDiffRectangle(Array *array, PDFRectangle *rect) {
static PDFRectangle *parseDiffRectangle(Array *array, PDFRectangle *rect) {
PDFRectangle *newRect = NULL;
if (array->getLength() == 4) {
// deltas
......
......@@ -1345,7 +1345,7 @@ static inline Guint sha256sigma1(Guint x) {
return rotr(x, 17) ^ rotr(x, 19) ^ (x >> 10);
}
void sha256HashBlock(Guchar *blk, Guint *H) {
static void sha256HashBlock(Guchar *blk, Guint *H) {
Guint W[64];
Guint a, b, c, d, e, f, g, h;
Guint T1, T2;
......
......@@ -565,7 +565,7 @@ static struct CombiningTable combiningTable[] = {
};
// returning combining versions of characters
Unicode getCombiningChar(Unicode u) {
static Unicode getCombiningChar(Unicode u) {
int len = sizeof(combiningTable) / sizeof(combiningTable[0]);
for (int i = 0; i < len; ++i) {
if (u == combiningTable[i].base)
......
......@@ -34,7 +34,7 @@
#include "Link.h"
#include "Rendition.h"
bool operator==( const Ref &r1, const Ref &r2 )
static bool operator==( const Ref &r1, const Ref &r2 )
{
return r1.num == r2.num && r1.gen == r2.gen;
}
......
......@@ -39,7 +39,7 @@ namespace Poppler {
namespace Debug {
void qDebugDebugFunction(const QString &message, const QVariant & /*closure*/)
static void qDebugDebugFunction(const QString &message, const QVariant & /*closure*/)
{
qDebug() << message;
}
......@@ -57,7 +57,7 @@ namespace Debug {
Debug::debugClosure = closure;
}
void qt4ErrorFunction(void * /*data*/, ErrorCategory /*category*/, Goffset pos, char *msg)
static void qt4ErrorFunction(void * /*data*/, ErrorCategory /*category*/, Goffset pos, char *msg)
{
QString emsg;
......@@ -162,7 +162,7 @@ namespace Debug {
return QStringToUnicodeGooString(dt.toUTC().toString("yyyyMMddhhmmss+00'00'"));
}
void linkActionToTocItem( ::LinkAction * a, DocumentData * doc, QDomElement * e )
static void linkActionToTocItem( ::LinkAction * a, DocumentData * doc, QDomElement * e )
{
if ( !a || !e )
return;
......
......@@ -13,12 +13,12 @@ private slots:
void checkDests_xr02();
};
bool isDestinationValid_pageNumber( const Poppler::LinkDestination *dest, const Poppler::Document *doc )
static bool isDestinationValid_pageNumber( const Poppler::LinkDestination *dest, const Poppler::Document *doc )
{
return dest->pageNumber() > 0 && dest->pageNumber() <= doc->numPages();
}
bool isDestinationValid_name( const Poppler::LinkDestination *dest )
static bool isDestinationValid_name( const Poppler::LinkDestination *dest )
{
return !dest->destinationName().isEmpty();
}
......
......@@ -6,7 +6,7 @@
#include <poppler-qt4.h>
#include <poppler-form.h>
std::ostream& operator<< (std::ostream &out, Poppler::FormField::FormType type)
static std::ostream& operator<< (std::ostream &out, Poppler::FormField::FormType type)
{
switch (type) {
case Poppler::FormField::FormButton: out << "Button"; break;
......@@ -17,7 +17,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::FormField::FormType type)
return out;
}
std::ostream& operator<< (std::ostream &out, Poppler::FormFieldButton::ButtonType type)
static std::ostream& operator<< (std::ostream &out, Poppler::FormFieldButton::ButtonType type)
{
switch (type) {
case Poppler::FormFieldButton::Push: out << "Push"; break;
......@@ -27,7 +27,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::FormFieldButton::ButtonTyp
return out;
}
std::ostream& operator<< (std::ostream &out, Poppler::FormFieldText::TextType type)
static std::ostream& operator<< (std::ostream &out, Poppler::FormFieldText::TextType type)
{
switch (type) {
case Poppler::FormFieldText::Normal: out << "Normal"; break;
......@@ -37,7 +37,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::FormFieldText::TextType ty
return out;
}
std::ostream& operator<< (std::ostream &out, Poppler::FormFieldChoice::ChoiceType type)
static std::ostream& operator<< (std::ostream &out, Poppler::FormFieldChoice::ChoiceType type)
{
switch (type) {
case Poppler::FormFieldChoice::ComboBox: out << "ComboBox"; break;
......@@ -46,7 +46,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::FormFieldChoice::ChoiceTyp
return out;
}
std::ostream& operator<< (std::ostream &out, Qt::Alignment alignment)
static std::ostream& operator<< (std::ostream &out, Qt::Alignment alignment)
{
switch (alignment) {
case Qt::AlignLeft: out << "Left"; break;
......@@ -62,13 +62,13 @@ std::ostream& operator<< (std::ostream &out, Qt::Alignment alignment)
return out;
}
std::ostream& operator<< (std::ostream &out, const QString &string)
static std::ostream& operator<< (std::ostream &out, const QString &string)
{
out << string.toUtf8().constData();
return out;
}
std::ostream& operator<< (std::ostream &out, const QRectF &rect)
static std::ostream& operator<< (std::ostream &out, const QRectF &rect)
{
out << QString("top: %1 left: %2 width: %3 height: %4").arg(rect.x()).arg(rect.y()).arg(rect.width()).arg(rect.height());
return out;
......
......@@ -34,7 +34,7 @@
#include "Link.h"
#include "Rendition.h"
bool operator==( const Ref &r1, const Ref &r2 )
static bool operator==( const Ref &r1, const Ref &r2 )
{
return r1.num == r2.num && r1.gen == r2.gen;
}
......
......@@ -39,7 +39,7 @@ namespace Poppler {
namespace Debug {
void qDebugDebugFunction(const QString &message, const QVariant & /*closure*/)
static void qDebugDebugFunction(const QString &message, const QVariant & /*closure*/)
{
qDebug() << message;
}
......@@ -57,7 +57,7 @@ namespace Debug {
Debug::debugClosure = closure;
}
void qt5ErrorFunction(void * /*data*/, ErrorCategory /*category*/, Goffset pos, char *msg)
static void qt5ErrorFunction(void * /*data*/, ErrorCategory /*category*/, Goffset pos, char *msg)
{
QString emsg;
......@@ -162,7 +162,7 @@ namespace Debug {
return QStringToUnicodeGooString(dt.toUTC().toString("yyyyMMddhhmmss+00'00'"));
}
void linkActionToTocItem( ::LinkAction * a, DocumentData * doc, QDomElement * e )
static void linkActionToTocItem( ::LinkAction * a, DocumentData * doc, QDomElement * e )
{
if ( !a || !e )
return;
......
......@@ -13,12 +13,12 @@ private slots:
void checkDests_xr02();
};
bool isDestinationValid_pageNumber( const Poppler::LinkDestination *dest, const Poppler::Document *doc )
static bool isDestinationValid_pageNumber( const Poppler::LinkDestination *dest, const Poppler::Document *doc )
{
return dest->pageNumber() > 0 && dest->pageNumber() <= doc->numPages();
}
bool isDestinationValid_name( const Poppler::LinkDestination *dest )
static bool isDestinationValid_name( const Poppler::LinkDestination *dest )
{
return !dest->destinationName().isEmpty();
}
......
......@@ -7,7 +7,7 @@
#include <poppler-qt5.h>
#include <poppler-form.h>
std::ostream& operator<< (std::ostream &out, Poppler::FormField::FormType type)
static std::ostream& operator<< (std::ostream &out, Poppler::FormField::FormType type)
{
switch (type) {
case Poppler::FormField::FormButton: out << "Button"; break;
......@@ -18,7 +18,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::FormField::FormType type)
return out;
}
std::ostream& operator<< (std::ostream &out, Poppler::FormFieldButton::ButtonType type)
static std::ostream& operator<< (std::ostream &out, Poppler::FormFieldButton::ButtonType type)
{
switch (type) {
case Poppler::FormFieldButton::Push: out << "Push"; break;
......@@ -28,7 +28,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::FormFieldButton::ButtonTyp
return out;
}
std::ostream& operator<< (std::ostream &out, Poppler::FormFieldText::TextType type)
static std::ostream& operator<< (std::ostream &out, Poppler::FormFieldText::TextType type)
{
switch (type) {
case Poppler::FormFieldText::Normal: out << "Normal"; break;
......@@ -38,7 +38,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::FormFieldText::TextType ty
return out;
}
std::ostream& operator<< (std::ostream &out, Poppler::FormFieldChoice::ChoiceType type)
static std::ostream& operator<< (std::ostream &out, Poppler::FormFieldChoice::ChoiceType type)
{
switch (type) {
case Poppler::FormFieldChoice::ComboBox: out << "ComboBox"; break;
......@@ -47,7 +47,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::FormFieldChoice::ChoiceTyp
return out;
}
std::ostream& operator<< (std::ostream &out, Poppler::SignatureValidationInfo::SignatureStatus status)
static std::ostream& operator<< (std::ostream &out, Poppler::SignatureValidationInfo::SignatureStatus status)
{
switch (status) {
case Poppler::SignatureValidationInfo::SignatureValid: out << "Valid"; break;
......@@ -61,7 +61,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::SignatureValidationInfo::S
return out;
}
std::ostream& operator<< (std::ostream &out, Poppler::SignatureValidationInfo::CertificateStatus status)
static std::ostream& operator<< (std::ostream &out, Poppler::SignatureValidationInfo::CertificateStatus status)
{
switch (status) {
case Poppler::SignatureValidationInfo::CertificateTrusted: out << "Trusted"; break;
......@@ -75,7 +75,7 @@ std::ostream& operator<< (std::ostream &out, Poppler::SignatureValidationInfo::C
return out;
}
std::ostream& operator<< (std::ostream &out, Qt::Alignment alignment)
static std::ostream& operator<< (std::ostream &out, Qt::Alignment alignment)
{
switch (alignment) {
case Qt::AlignLeft: out << "Left"; break;
......@@ -91,13 +91,13 @@ std::ostream& operator<< (std::ostream &out, Qt::Alignment alignment)
return out;
}
std::ostream& operator<< (std::ostream &out, const QString &string)
static std::ostream& operator<< (std::ostream &out, const QString &string)
{
out << string.toUtf8().constData();
return out;
}
std::ostream& operator<< (std::ostream &out, const QRectF &rect)
static std::ostream& operator<< (std::ostream &out, const QRectF &rect)
{
out << QString("top: %1 left: %2 width: %3 height: %4").arg(rect.x()).arg(rect.y()).arg(rect.width()).arg(rect.height());
return out;
......
......@@ -8,6 +8,10 @@ get any visual feedback during testing.
#include "splash/SplashBitmap.h"
void PreviewBitmapInit(void);
void PreviewBitmapDestroy(void);
void PreviewBitmapSplash(SplashBitmap *bmpSplash);
void PreviewBitmapSplash(SplashBitmap *bmpSplash)
{
}
......
......@@ -196,12 +196,12 @@ static bool gfLoadOnly = false;
#define DIR_SEP_STR "/"
#endif
void memzero(void *data, size_t len)
static void memzero(void *data, size_t len)
{
memset(data, 0, len);
}
void *zmalloc(size_t len)
static void *zmalloc(size_t len)
{
void *data = malloc(len);
if (data)
......@@ -211,7 +211,7 @@ void *zmalloc(size_t len)
/* Concatenate 4 strings. Any string can be NULL.
Caller needs to free() memory. */
char *str_cat4(const char *str1, const char *str2, const char *str3, const char *str4)
static char *str_cat4(const char *str1, const char *str2, const char *str3, const char *str4)
{
char *str;
char *tmp;
......@@ -252,12 +252,12 @@ char *str_cat4(const char *str1, const char *str2, const char *str3, const char
return str;
}
char *str_dup(const char *str)
static char *str_dup(const char *str)
{
return str_cat4(str, NULL, NULL, NULL);
}
bool str_eq(const char *str1, const char *str2)
static bool str_eq(const char *str1, const char *str2)
{
if (!str1 && !str2)
return true;
......@@ -268,7 +268,7 @@ bool str_eq(const char *str1, const char *str2)
return false;
}
bool str_ieq(const char *str1, const char *str2)
static bool str_ieq(const char *str1, const char *str2)
{
if (!str1 && !str2)
return true;
......@@ -279,7 +279,7 @@ bool str_ieq(const char *str1, const char *str2)
return false;
}
bool str_endswith(const char *txt, const char *end)
static bool str_endswith(const char *txt, const char *end)
{
size_t end_len;
size_t txt_len;
......@@ -298,7 +298,7 @@ bool str_endswith(const char *txt, const char *end)
/* TODO: probably should move to some other file and change name to
sleep_milliseconds */
void sleep_milliseconds(int milliseconds)
static void sleep_milliseconds(int milliseconds)
{
#ifdef _WIN32
Sleep((DWORD)milliseconds);
......@@ -327,7 +327,7 @@ void sleep_milliseconds(int milliseconds)
}
#ifndef HAVE_STRCPY_S
void strcpy_s(char* dst, size_t dst_size, const char* src)
static void strcpy_s(char* dst, size_t dst_size, const char* src)
{
size_t src_size = strlen(src) + 1;
if (src_size <= dst_size)
......@@ -342,7 +342,7 @@ void strcpy_s(char* dst, size_t dst_size, const char* src)
#endif
#ifndef HAVE_STRCAT_S
void strcat_s(char *dst, size_t dst_size, const char* src)
static void strcat_s(char *dst, size_t dst_size, const char* src)
{
size_t dst_len = strlen(dst);
if (dst_len >= dst_size) {
......@@ -390,7 +390,7 @@ static void splashColorSet(SplashColorPtr col, Guchar red, Guchar green, Guchar
}
}
void SplashColorsInit(void)
static void SplashColorsInit(void)
{
splashColorSet(SPLASH_COL_RED_PTR, 0xff, 0, 0, 0);
splashColorSet(SPLASH_COL_GREEN_PTR, 0, 0xff, 0, 0);
......@@ -515,7 +515,7 @@ static void win_correct_path_for_FindFirstFile(char *path, int path_max_len)
}
#endif
FindFileState *find_file_open(const char *path, const char *pattern)
static FindFileState *find_file_open(const char *path, const char *pattern)
{
FindFileState *s;
......@@ -544,7 +544,7 @@ void *StandardSecurityHandler::getAuthData()
}
#endif
char *makepath(char *buf, int buf_size, const char *path,
static char *makepath(char *buf, int buf_size, const char *path,
const char *filename)
{
strcpy_s(buf, buf_size, path);
......@@ -568,7 +568,7 @@ static int skip_matching_file(const char *filename)
}
#endif
int find_file_next(FindFileState *s, char *filename, int filename_size_max)
static int find_file_next(FindFileState *s, char *filename, int filename_size_max)
{
#ifdef _WIN32
int fFound;
......@@ -635,7 +635,7 @@ CheckFile:
#endif
}
void find_file_close(FindFileState *s)
static void find_file_close(FindFileState *s)
{
#ifdef _WIN32
if (INVALID_HANDLE_VALUE != s->dir)
......@@ -647,7 +647,7 @@ void find_file_close(FindFileState *s)
free(s);
}
int StrList_Len(StrList **root)
static int StrList_Len(StrList **root)
{
int len = 0;
StrList * cur;
......@@ -662,7 +662,7 @@ int StrList_Len(StrList **root)
return len;
}
int StrList_InsertAndOwn(StrList **root, char *txt)
static int StrList_InsertAndOwn(StrList **root, char *txt)
{
StrList * el;
assert(root && txt);
......@@ -678,7 +678,7 @@ int StrList_InsertAndOwn(StrList **root, char *txt)
return true;
}
int StrList_Insert(StrList **root, char *txt)
static int StrList_Insert(StrList **root, char *txt)
{
char *txtDup;
......@@ -696,7 +696,7 @@ int StrList_Insert(StrList **root, char *txt)
return true;
}
StrList* StrList_RemoveHead(StrList **root)
static StrList* StrList_RemoveHead(StrList **root)
{
StrList *tmp;
assert(root);
......@@ -711,7 +711,7 @@ StrList* StrList_RemoveHead(StrList **root)
return tmp;
}
void StrList_FreeElement(StrList *el)
static void StrList_FreeElement(StrList *el)
{
if (!el)
return;
......@@ -719,7 +719,7 @@ void StrList_FreeElement(StrList *el)
free((void*)el);
}
void StrList_Destroy(StrList **root)
static void StrList_Destroy(StrList **root)
{
StrList * cur;
StrList * next;
......@@ -736,15 +736,15 @@ void StrList_Destroy(StrList **root)
}
#ifndef _WIN32
void OutputDebugString(const char *txt)
/*static void OutputDebugString(const char *txt)
{
/* do nothing */
}
// do nothing
}*/
#define _snprintf snprintf
#define _vsnprintf vsnprintf
#endif
void my_error(void *, ErrorCategory, Goffset pos, char *msg) {
static void my_error(void *, ErrorCategory, Goffset pos, char *msg) {
#if 0
char buf[4096], *p = buf;
......@@ -798,7 +798,7 @@ void my_error(void *, ErrorCategory, Goffset pos, char *msg) {
#endif
}
void LogInfo(const char *fmt, ...)
static void LogInfo(const char *fmt, ...)
{
va_list args;
char buf[4096], *p = buf;
......@@ -1128,7 +1128,7 @@ Exit:
#include <sys/types.h>
#include <sys/stat.h>
bool IsDirectoryName(char *path)
static bool IsDirectoryName(char *path)
{
struct _stat buf;
int result;
......@@ -1143,7 +1143,7 @@ bool IsDirectoryName(char *path)
return false;
}
bool IsFileName(char *path)
static bool IsFileName(char *path)
{
struct _stat buf;
int result;
......@@ -1158,20 +1158,20 @@ bool IsFileName(char *path)
return false;
}
#else
bool IsDirectoryName(char *path)
static bool IsDirectoryName(char *path)
{
/* TODO: implement me */
return false;
}
bool IsFileName(char *path)
static bool IsFileName(char *path)
{
/* TODO: implement me */
return true;
}
#endif
bool IsPdfFileName(char *path)
static bool IsPdfFileName(char *path)
{
if (str_endswith(path, ".pdf"))
return true;
......
......@@ -186,7 +186,7 @@ static void printInfoDate(Dict *infoDict, const char *key, const char *text) {
}
}
void printISODate(Dict *infoDict, const char *key, const char *text)
static void printISODate(Dict *infoDict, const char *key, const char *text)
{
char *s;
int year, mon, day, hour, min, sec, tz_hour, tz_minute;
......@@ -428,7 +428,7 @@ static void printDestinations(PDFDoc *doc, UnicodeMap *uMap) {
}
}
void printInfo(PDFDoc *doc, UnicodeMap *uMap, long long filesize, GBool multiPage) {
static void printInfo(PDFDoc *doc, UnicodeMap *uMap, long long filesize, GBool multiPage) {
Page *page;
char buf[256];
double w, h, wISO, hISO;
......
......@@ -48,7 +48,7 @@ static const ArgDesc argDesc[] = {
{NULL}
};
bool extractPages (const char *srcFileName, const char *destFileName) {
static bool extractPages (const char *srcFileName, const char *destFileName) {
char pathName[4096];
GooString *gfileName = new GooString (srcFileName);
PDFDoc *doc = new PDFDoc (gfileName, NULL, NULL, NULL);
......
......@@ -30,7 +30,7 @@
#include "GlobalParams.h"
#include "SignatureInfo.h"
const char * getReadableSigState(SignatureValidationStatus sig_vs)
static const char * getReadableSigState(SignatureValidationStatus sig_vs)
{
switch(sig_vs) {
case SIGNATURE_VALID:
......@@ -53,7 +53,7 @@ const char * getReadableSigState(SignatureValidationStatus sig_vs)
}
}
const char * getReadableCertState(CertificateValidationStatus cert_vs)
static const char * getReadableCertState(CertificateValidationStatus cert_vs)
{
switch(cert_vs) {
case CERTIFICATE_TRUSTED:
......@@ -79,7 +79,7 @@ const char * getReadableCertState(CertificateValidationStatus cert_vs)
}
}
char *getReadableTime(time_t unix_time)
static char *getReadableTime(time_t unix_time)
{
char * time_str = (char *) gmalloc(64);
strftime(time_str, 64, "%b %d %Y %H:%M:%S", localtime(&unix_time));
......
......@@ -483,7 +483,7 @@ static void printInfoDate(FILE *f, Dict *infoDict, const char *key, const char *
}
}
void printLine(FILE *f, TextLine *line) {
static void printLine(FILE *f, TextLine *line) {
double xMin, yMin, xMax, yMax;
double lineXMin = 0, lineYMin = 0, lineXMax = 0, lineYMax = 0;
TextWord *word;
......
......@@ -38,7 +38,7 @@ static const ArgDesc argDesc[] = {
{NULL}
};
void doMergeNameTree(PDFDoc *doc, XRef *srcXRef, XRef *countRef, int oldRefNum, int newRefNum, Dict *srcNameTree, Dict *mergeNameTree, int numOffset) {
static void doMergeNameTree(PDFDoc *doc, XRef *srcXRef, XRef *countRef, int oldRefNum, int newRefNum, Dict *srcNameTree, Dict *mergeNameTree, int numOffset) {
Object mergeNameArray = mergeNameTree->lookup("Names");
Object srcNameArray = srcNameTree->lookup("Names");
if (mergeNameArray.isArray() && srcNameArray.isArray()) {
......@@ -95,7 +95,7 @@ void doMergeNameTree(PDFDoc *doc, XRef *srcXRef, XRef *countRef, int oldRefNum,
}
}
void doMergeNameDict(PDFDoc *doc, XRef *srcXRef, XRef *countRef, int oldRefNum, int newRefNum, Dict *srcNameDict, Dict *mergeNameDict, int numOffset) {
static void doMergeNameDict(PDFDoc *doc, XRef *srcXRef, XRef *countRef, int oldRefNum, int newRefNum, Dict *srcNameDict, Dict *mergeNameDict, int numOffset) {
for (int i = 0; i < mergeNameDict->getLength(); i++) {
const char *key = mergeNameDict->getKey(i);
Object mergeNameTree = mergeNameDict->lookup(key);
......@@ -110,7 +110,7 @@ void doMergeNameDict(PDFDoc *doc, XRef *srcXRef, XRef *countRef, int oldRefNum,
}
}
void doMergeFormDict(Dict *srcFormDict, Dict *mergeFormDict, int numOffset) {
static void doMergeFormDict(Dict *srcFormDict, Dict *mergeFormDict, int numOffset) {
Object srcFields = srcFormDict->lookup("Fields");
Object mergeFields = mergeFormDict->lookup("Fields");
if (srcFields.isArray() && mergeFields.isArray()) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment