GSoC Project | Basic Support for Trace Compass

Ravindra Kumar Meena rmeena840 at
Mon Aug 12 10:27:07 UTC 2019

> This is too complicated:
> +    strcpy( filename, "event_" );
>       snprintf( file_index, sizeof( file_index ), "%ld", i );
>       strcat( filename, file_index );
> In addition, the strcpy() and strcat() functions are dangerous to use.
> Why don't you simply use:
> snprintf( filename, sizeof( filename ), "event_%zu", i );
> ?
> The i is of type size_t, so %ld is not the right format. Firstly, the
> signedness is wrong, secondly using "l" is not portable.


Have a look.

What's the procedure for getting code merged? Do I have to raise PR on
GitHub or simply send a patch on devel?

*Ravindra Kumar Meena*,
B. Tech. Computer Science and Engineering,
Indian Institute of Technology (Indian School of Mines)
<>, Dhanbad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the devel mailing list