[genivi-dlt] [Patch] Several patchs for Bugfix and improvements

Andersson, Gunnar gunnar.x.andersson at volvocars.com
Tue Aug 30 05:30:55 EDT 2016


A really big set of patches.  Thanks for the input.

I only reviewed the first patch, sorry.  It is not something I have time
to do personally very often. :-)

But there's something here that I have seen in this and other
project in many places:

+  if( *buf != NULL )
+  {
+    free(*buf);
+    *buf = NULL;
+  }
+

It is actually not necessary to check if a pointer is NULL before free().  
The C standard requires free(NULL) to have no effect.  I still agree you 
are doing the right thing to assign NULL to the variable itself, especially
in this case when it is an indirect pointer that lives inside of some
other data structure.


- Gunnar 
[1] http://linux.die.net/man/3/free  "If ptr is NULL, no operation is performed"
[2] http://stackoverflow.com/questions/1912325/checking-for-null-before-calling-free
(and the C standard says the same)

-- 
Gunnar Andersson
Lead Architect, GENIVI Alliance
Infotainment, Volvo Car Corporation

-----Original Message-----
From: genivi-diagnostic-log-and-trace [mailto:genivi-diagnostic-log-and-trace-bounces at mailman1.genivi.org] On Behalf Of yusuke-sato at apn.alpine.co.jp
Sent: den 30 augusti 2016 11:03
To: genivi-diagnostic-log-and-trace at lists.genivi.org
Cc: k-takahashi at apn.alpine.co.jp
Subject: [genivi-dlt] [Patch] Several patchs for Bugfix and improvements

Hello, Alex & mailing List listeners,

please find attached patches for bugfix and improvements.
I hope some of these patches helps you.

Short description of patches:

0001: 
Fix memory leak issue in dlt-dbus.

0002:
Fix file name broken issue then file is transferred on 64 bit OS.

0003:
Accelerate file transfer speed in dlt-system

0004:
Fix segmentation fault issue in checking buffer usage.

0005:
Add debug log for file transfer feature of dlt-system

0006:
Fix the issue that handle of /tmp/dlt (daemon FIFO) never reset if 
dlt-daemon is killed

0007:
Add configuration of daemon FIFO size

0008:
Add configuration of option of Get Log Info response during context 
registration.
If we change the option in dlt.conf, we can reduce unnecessary context 
information.
Option value is as follows.
# Apid and Ctid Only = 3, with LogLevel = 4, with TraceStatus = 5, with LL 
and TS = 6, with LL, TS, and Description = 7 

0009:
Fix the issue that dlt-daemon overwrites ECU ID even if user log message 
already has the ECU ID that is not default value

0010:
Fix the issue that memory for context description is not freed.


Any feedback is very appreciated.














Thanks
Best regards.
Yusuke Sato
--------------------------------------------------------------------------
ATTENTION:This e-mail and any files transmitted with it are the property of 
Alpine Electronics, Inc and/or its affiliates, may be privileged and/or 
confidential, and are intended solely for the use of the individual or entity 
to whom this e-mail is addressed. If you are not one of the named recipients 
or otherwise have reason to believe that you have received this e-mail in 
error, please notify the sender and delete this message immediately from your
computer. Any other use, retention, dissemination, forwarding, printing or 
copying of this e-mail is strictly prohibited.

注意:このEメールおよび添付ファイルはアルパイン株式会社および関連子会社の
資産であり、法的特権を持つ情報および秘密情報を含んでいる可能性があります。
また、宛先とした特定の個人もしくは団体、あるいは、それらが指定する人によって
のみ、読まれることを意図しています。もし、あなたがこのEメールの意図された
受信者でないなら、または、誤って送信されたものを受領したと思われる場合は、
速やかに送信者へ通知の上、このEメールを削除してください。また、他の目的への
利用、配布、転送、印刷、コピーは固く禁止されています。
--------------------------------------------------------------------------


More information about the genivi-diagnostic-log-and-trace mailing list