[Bugfix][T106BUG-562] set log file size as 1M when input param less than 1M for api lynq_syslog_set_file_size
Only Configure: No
Affected branch: master
Affected module: log
Is it affected on both ZXIC and MTK: only ZXIC
Self-test: Yes
Doc Update: No
Change-Id: Icc5311e98bb1e84ca6ca721ce2cea02667fde368
diff --git a/cap/zx297520v3/src/lynq/lib/liblynq-log/log-riltel/log.cpp b/cap/zx297520v3/src/lynq/lib/liblynq-log/log-riltel/log.cpp
index 581fee8..6256d4f 100755
--- a/cap/zx297520v3/src/lynq/lib/liblynq-log/log-riltel/log.cpp
+++ b/cap/zx297520v3/src/lynq/lib/liblynq-log/log-riltel/log.cpp
@@ -311,6 +311,10 @@
{
value = 100;
}
+ else if( value < 1)
+ {
+ value = 1;
+ }
snprintf(lynq_syslog_data,sizeof(lynq_syslog_data),"%d",value);//Converts bytes to M
if (0 != sc_cfg_set("syslog_file_size", lynq_syslog_data))
{