From 05ce4e2b956f7db45d7d2d44d5e2297230addc5b Mon Sep 17 00:00:00 2001 From: Joseph Hickey Date: Fri, 25 Jun 2021 15:15:39 -0400 Subject: [PATCH] Fix #1082, increase UT symbol dump size limit For the MCP750, the symbol table fairly large and requires a considerably larger limit to avoid the OS_ERR_OUTPUT_TOO_LARGE limit. This also uses a different name, so that the user can actually see the symbol dump file if they want (otherwise the next test overwrites the file). --- .../osloader-test/ut_osloader_symtable_test.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/unit-tests/osloader-test/ut_osloader_symtable_test.c b/src/unit-tests/osloader-test/ut_osloader_symtable_test.c index 204d0cd35..96333b1b2 100644 --- a/src/unit-tests/osloader-test/ut_osloader_symtable_test.c +++ b/src/unit-tests/osloader-test/ut_osloader_symtable_test.c @@ -35,6 +35,14 @@ ** Macros **--------------------------------------------------------------------------------*/ +/** + * The size limit to pass for OS_SymbolTableDump nominal test + * + * This must be large enough to actually accomodate all of the symbols + * in the target system. + */ +#define UT_SYMTABLE_SIZE_LIMIT 1048576 + /*--------------------------------------------------------------------------------* ** Data types **--------------------------------------------------------------------------------*/ @@ -188,9 +196,9 @@ void UT_os_symbol_table_dump_test() /*-----------------------------------------------------*/ /* #3 Nominal */ - if (UT_NOMINAL_OR_NOTIMPL(OS_SymbolTableDump(UT_OS_GENERIC_MODULE_DIR "SymbolFile.dat", 32000))) + if (UT_NOMINAL_OR_NOTIMPL(OS_SymbolTableDump(UT_OS_GENERIC_MODULE_DIR "SymbolReal.dat", UT_SYMTABLE_SIZE_LIMIT))) { - UT_RETVAL(OS_SymbolTableDump(UT_OS_GENERIC_MODULE_DIR "SymbolFile.dat", 0), OS_ERR_OUTPUT_TOO_LARGE); + UT_RETVAL(OS_SymbolTableDump(UT_OS_GENERIC_MODULE_DIR "SymbolZero.dat", 0), OS_ERR_OUTPUT_TOO_LARGE); } }