GSoC Project | Basic Support for Trace Compass
Ravindra Kumar Meena
rmeena840 at gmail.com
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.
>
Okay
https://github.com/rmeena840/rtems-tools/commit/1ffbe7d5dcea741a3e7ceec8ded869d38c20081f
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)
<https://www.iitism.ac.in/>, Dhanbad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20190812/58d61d85/attachment-0002.html>
More information about the devel
mailing list