C++ find code responsible for log rotation in android

Basically there is a shared library from android phone that creates log file .bin, but inside contents are text so changing extension to .txt makes it readable.

However size is limited to 3mb after this it starts to rotate the text, i have source code for the shared library and trying to find what line of code is responsible for rotating the text or where the size is specified.

functions from OsUtils

static CAMX_INLINE INT VSNPrintF(
        CHAR*       pDst,
        SIZE_T      sizeDst,
        const CHAR* pFormat,
        va_list     argptr)
    {
        INT numCharWritten = 0;
#if defined(_LINUX)
        numCharWritten = vsnprintf(pDst, sizeDst, pFormat, argptr);
#elif defined(_WIN32)
        numCharWritten = vsnprintf_s(pDst, sizeDst, _TRUNCATE, pFormat, argptr);
#elif defined(ANDROID)
        numCharWritten = vsnprintf(pDst, sizeDst, pFormat, argptr);
#else
        CAMX_STATIC_ASSERT_MESSAGE(FALSE, "Unsupported Target");
#endif // defined(_LINUX)
        return numCharWritten;
    }
 
 
static CAMX_INLINE INT SNPrintF(
        CHAR*       pDst,
        SIZE_T      sizeDst,
        const CHAR* pFormat,
                    ...)
    {
        INT     numCharWritten;
        va_list args;
 
        va_start(args, pFormat);
        numCharWritten = VSNPrintF(pDst, sizeDst, pFormat, args);
        va_end(args);
 
        return numCharWritten;
    }
 
FILE* OsUtils::FOpen(
    const CHAR* pFilename,
    const CHAR* pMode)
{
    return fopen(pFilename, pMode);
}
 
 
VOID OsUtils::GetDateTime(
    CamxDateTime* pDateTime)
{
    CAMX_ASSERT(NULL != pDateTime);
    struct timeval  timeValue;
    struct tm*      pTimeInfo   = NULL;
    INT             result      = 0;
 
    result = gettimeofday(&timeValue, NULL);
    if (0 == result)
    {
        pTimeInfo = localtime(&timeValue.tv_sec);
        if (NULL != pTimeInfo)
        {
            pDateTime->seconds                           = static_cast<UINT32>(pTimeInfo->tm_sec);
            pDateTime->microseconds                   = static_cast<UINT32>(timeValue.tv_usec);
            pDateTime->minutes                           = static_cast<UINT32>(pTimeInfo->tm_min);
            pDateTime->hours                              = static_cast<UINT32>(pTimeInfo->tm_hour);
            pDateTime->dayOfMonth                     = static_cast<UINT32>(pTimeInfo->tm_mday);
            pDateTime->month                             = static_cast<UINT32>(pTimeInfo->tm_mon);
            pDateTime->year                               = static_cast<UINT32>(pTimeInfo->tm_year);
            pDateTime->weekday                         = static_cast<UINT32>(pTimeInfo->tm_wday);
            pDateTime->yearday                          = static_cast<UINT32>(pTimeInfo->tm_yday);
            pDateTime->dayLightSavingTimeFlag   = static_cast<UINT32>(pTimeInfo->tm_isdst);
        }
    }
}
 
INT OsUtils::FPrintF(
    FILE*       pFile,
    const CHAR* pFormat,
                ...)
{
    INT     result;
    va_list argptr;
 
    va_start(argptr, pFormat);
    result = vfprintf(pFile, pFormat, argptr);
    va_end(argptr);
 
    return result;
}
 
CamxResult OsUtils::FClose(
    FILE* pFile)
{
    CamxResult result = CamxResultSuccess;
    if (0 != fclose(pFile))
    {
        result = CamxResultEFailed;
    }
    return result;
} 

I searched all code base of application globally with IDE for debugLogFilename as this is name of setting that define log file name and pDebugLogFile based on the code is also used and only following lines of code mention this variables.

//i added this line for clarity of explanation
m_pStaticSettings->debugLogFilename=Log_file
 
 
if ('' != m_pStaticSettings->debugLogFilename[0])
{
    FILE*   pDebugLogFile           = NULL;
    CHAR    filename[FILENAME_MAX]  = {0};
    OsUtils::SNPrintF(filename, sizeof(filename),
                      "%s%s%s.bin",
                      ConfigFileDirectory, PathSeparator, m_pStaticSettings->debugLogFilename);
 
    pDebugLogFile                      = OsUtils::FOpen(filename, "w");
    newLogInfo.pDebugLogFile    = pDebugLogFile;
}
else
{
    newLogInfo.pDebugLogFile = NULL;
} 


m_debugLogInfo.pDebugLogFile = pNewLogInfo->pDebugLogFile;
 
if (NULL != g_logInfo.pDebugLogFile)
{
    OsUtils::FClose(g_logInfo.pDebugLogFile);
    g_logInfo.pDebugLogFile = NULL;
}
 
if (NULL != g_logInfo.pDebugLogFile)
{
    CamxDateTime systemDateTime;
    OsUtils::GetDateTime(&systemDateTime);
    OsUtils::FPrintF(g_logInfo.pDebugLogFile, "%02d-%02d %02d:%02d:%02d:%03d %sn", systemDateTime.month,
                           systemDateTime.dayOfMonth, systemDateTime.hours, systemDateTime.minutes, systemDateTime.seconds,
                           systemDateTime.microseconds / 1000, logText);
}
 
if (NULL != CamX::g_logInfo.pDebugLogFile)
{
    CamX::OsUtils::FPrintF(CamX::g_logInfo.pDebugLogFile, "%sn", assertText);
}

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật