[Forensics-changes] [SCM] debian-forensics/libguytools branch, debian, updated. debian/1.0.4-2-4-g9f66495
Michael Prokop
mika at debian.org
Fri Jan 29 03:48:08 UTC 2010
The following commit has been merged in the debian branch:
commit fff051e2c9503b37cc7bbbf13608f7e6796ac2d7
Author: Michael Prokop <mika at debian.org>
Date: Fri Jan 29 04:30:09 2010 +0100
Merging upstream version 1.1.1
diff --git a/alltools b/alltools
index 6de1c1b..542ab2d 100755
--- a/alltools
+++ b/alltools
@@ -26,7 +26,7 @@ else
DoCompile=0
shift
else
- if [ "$1" == "dep" ] || [ "$1" == "makemake" ] || [ "$1" == "qmake-qt4" ]; then
+ if [ "$1" == "dep" ] || [ "$1" == "makemake" ] || [ "$1" == "qmake" ] || [ "$1" == "qmake-qt4" ]; then
DoClean=0
DoDep=1
DoCompile=0
@@ -137,7 +137,7 @@ fi
TOOLS_VERSION=`head -n 1 debian/changelog`
TOOLS_VERSION="${TOOLS_VERSION%%)*}"
-TOOLS_VERSION="${TOOLS_VERSION##*(}" >libguytools_version.pro.inc
+TOOLS_VERSION="${TOOLS_VERSION##*(}"
echo "VERSION = ${TOOLS_VERSION%%-*}" >libguytools_version.pro.inc
diff --git a/cfg/toolcfg.cpp b/cfg/toolcfg.cpp
index cb2fe78..4bd5a3d 100644
--- a/cfg/toolcfg.cpp
+++ b/cfg/toolcfg.cpp
@@ -861,8 +861,8 @@ static APIRET ToolCfgSearchLine (t_pToolCfgContext pCfgContext)
pTmp = pCfgContext->pActLine + pCfgContext->ActLineLen;
if (*pTmp != '\0')
{
- if ((pTmp[0] == CHAR_LF) && (pTmp[1] == CHAR_CR) ||
- (pTmp[1] == CHAR_LF) && (pTmp[0] == CHAR_CR))
+ if (((pTmp[0] == CHAR_LF) && (pTmp[1] == CHAR_CR)) ||
+ ((pTmp[1] == CHAR_LF) && (pTmp[0] == CHAR_CR)))
pTmp += 2;
else pTmp += 1;
}
@@ -2334,8 +2334,8 @@ static APIRET ToolCfgBuildTemplate0 (FILE *pFile, t_int CfgParams, t_pint pEntri
Source = (t_ToolCfgAssignment) (pParamDescArray[i].Assign & CFGASN_SOURCE);
- if ((Source & CFGASN_CMD) && !(Source & CFGASN_CFG) && (CfgParams == FALSE) ||
- (Source & CFGASN_CFG) && (CfgParams == TRUE))
+ if (((Source & CFGASN_CMD) && !(Source & CFGASN_CFG) && (CfgParams == FALSE)) ||
+ ((Source & CFGASN_CFG) && (CfgParams == TRUE )))
{
CFG_CHK_APP (ToolCfgBuildHelp (pCfgDataDesc, NULL, &Len))
CFG_CHK_APP (ToolCfgMemAlloc ((void **)&pTmp1, (t_uint)Len, MEM_OPT_NONE, MemIdCfgHelpBuff))
diff --git a/include/toolglobalid.h b/include/toolglobalid.h
index 75b5635..3e9f729 100644
--- a/include/toolglobalid.h
+++ b/include/toolglobalid.h
@@ -49,7 +49,7 @@ CREATE_IDS (TOOL_SYSINFO , ID_BASE_TOOLS + 4*ID_OFFSET_SUBPROJECT)
/* ========================= GUYMAGER ============================== */
CREATE_BASE_ID (GUYMAGER, ID_BASE + 1*ID_OFFSET_PROJECT)
-CREATE_IDS (GUYMAGER_MAIN , ID_BASE_GUYMAGER + 0*ID_OFFSET_SUBPROJECT) // Reserve 2 subprojects for CAT-
+CREATE_IDS (GUYMAGER_MAIN , ID_BASE_GUYMAGER + 0*ID_OFFSET_SUBPROJECT)
#endif
diff --git a/libguytools.pro.inc b/libguytools.pro.inc
index 2cbe8e4..c292586 100644
--- a/libguytools.pro.inc
+++ b/libguytools.pro.inc
@@ -15,6 +15,7 @@ INCLUDEPATH += ../include
# result of it during compilation
DEFINES += "LIBGUYTOOLS_VERSION=\\\""$$VERSION"\\\""
+
QMAKE_CXXFLAGS_WARN_ON += -fmessage-length=0 # Tell g++ not to split messages into different lines
QMAKE_CXXFLAGS_RELEASE += -O3
diff --git a/log/toollog.cpp b/log/toollog.cpp
index ec6d648..bd884eb 100755
--- a/log/toollog.cpp
+++ b/log/toollog.cpp
@@ -89,6 +89,7 @@ void t_Log::vEntry (t_Level Level, const char *pFileName, const char *pFunctionN
struct tm *pNowTM;
FILE *pFile;
int wr;
+ static bool LogFileError = false; // Variable prevents us from repetitive log error messages
time (&NowT);
pNowTM = localtime (&NowT);
@@ -111,11 +112,14 @@ void t_Log::vEntry (t_Level Level, const char *pFileName, const char *pFunctionN
pFile = fopen64 (pLogFilename, "a");
if (pFile == NULL)
{
- printf ("\nLog file error: Can't be opened");
+ if (!LogFileError)
+ printf ("\nLog file error: Can't be opened");
+ LogFileError = true;
}
else
{
- fprintf (pFile, &LogLineHeader[0]);
+ LogFileError = false;
+ fprintf (pFile, "%s", &LogLineHeader[0]);
vfprintf (pFile, pFormat, pArguments);
fprintf (pFile, "\n");
fclose (pFile);
@@ -124,7 +128,7 @@ void t_Log::vEntry (t_Level Level, const char *pFileName, const char *pFunctionN
if (!LogInitialised || (pFile == NULL))
{
printf ("\n");
- printf (&LogLineHeader[0]);
+ printf ("%s", &LogLineHeader[0]);
vprintf (pFormat, pArguments);
}
LogMutex.unlock();
--
debian-forensics/libguytools
More information about the forensics-changes
mailing list