On 21/06/2019 13:20, Ravindra Kumar Meena wrote:
Hi,
I was able to store the event stream in file. I have sent the patch for
the same. It has only one warning that I have to discuss with you.
../misc/record/record-main.c:172:14: warning: ‘ns’ may be used
uninitialized in this function [-Wmaybe-uninitialized]
ctf_item.ns=ns;
^
../misc/record/record-main.c:147:12: note: ‘ns’ was declared here
uint32_t ns;
This is not a warning. It is an error. The ns variable is not set in the
else path.
It should look like this:
static void print_item( FILE *f, const client_item *item )
{
ctf_event ctf_item;
ctf_item.ns = item->ns;
ctf_item.cpu = item->cpu;
ctf_item.event = item->event;
ctf_item.data = item->data;
fwrite( &ctf_item, sizeof( ctf_item ), 1, f );
}
--
Sebastian Huber, embedded brains GmbH
Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone : +49 89 189 47 41-16
Fax : +49 89 189 47 41-09
E-Mail : sebastian.hu...@embedded-brains.de
PGP : Public key available on request.
Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
_______________________________________________
devel mailing list
devel@rtems.org
http://lists.rtems.org/mailman/listinfo/devel