Skip to content
Snippets Groups Projects
Commit ff59cb4b authored by Philippe Canal's avatar Philippe Canal
Browse files

Resolve snprintf truncation warning.

.../tree/tree/src/TTree.cxx: In member function ‘virtual TFile* TTree::ChangeFile(TFile*)’:
.../tree/tree/src/TTree.cxx:2642:33: warning: ‘%d’ directive output may be truncated writing between 1 and 11 bytes into a region of size between 1 and 10 [-Wformat-truncation=]
             snprintf(fcount,10, %s%d, uscore, fFileNumber);
                                 ^~~~~~
.../tree/tree/src/TTree.cxx:2642:33: note: directive argument in the range [-2147483648, 1]
.../tree/tree/src/TTree.cxx:2642:21: note: ‘snprintf’ output between 2 and 21 bytes into a destination of size 10
             snprintf(fcount,10, %s%d, uscore, fFileNumber);
             ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.../tree/tree/src/TTree.cxx:2632:33: warning: ‘%d’ directive output may be truncated writing between 1 and 10 bytes into a region of size between 1 and 10 [-Wformat-truncation=]
             snprintf(fcount,10, %s%d, uscore, fFileNumber);
                                 ^~~~~~
parent a1c8479f
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment