arduino-libraries / SD

SD Library for Arduino
http://arduino.cc/
GNU General Public License v3.0
179 stars 155 forks source link

Initialized integer #128

Closed Zbysekz closed 1 year ago

Zbysekz commented 1 year ago

Just simple fix - initialized integer to avoid warning. No effect on functionality

Warning: SD.cpp:462:14: warning: 'pathidx' may be used uninitialized in this function [-Wmaybe-uninitialized] filepath += pathidx; ^ SD.cpp:456:9: note: 'pathidx' was declared here int pathidx;

IDE 2.0.1 with enabled all compiler warnings

github-actions[bot] commented 1 year ago

Memory usage change @ 7d219125a3431b2a29fa61811c875076e0bb89a8

Board flash % RAM for global variables %
arduino:avr:leonardo :green_heart: -10 - 0 -0.03 - 0.0 0 - 0 0.0 - 0.0
arduino:avr:mega :green_heart: -10 - 0 -0.0 - 0.0 0 - 0 0.0 - 0.0
arduino:avr:nano :green_heart: -10 - 0 -0.03 - 0.0 0 - 0 0.0 - 0.0
arduino:mbed_nano:nano33ble 0 - 0 0.0 - 0.0 0 - 0 0.0 - 0.0
arduino:mbed_nano:nanorp2040connect :small_red_triangle: 0 - +4 0.0 - 0.0 0 - 0 0.0 - 0.0
arduino:mbed_portenta:envie_m4 :small_red_triangle: 0 - +64 0.0 - +0.01 0 - 0 0.0 - 0.0
arduino:mbed_portenta:envie_m7 :small_red_triangle: 0 - +64 0.0 - +0.01 0 - 0 0.0 - 0.0
arduino:megaavr:nona4809 :green_heart: -10 - 0 -0.02 - 0.0 0 - 0 0.0 - 0.0
arduino:sam:arduino_due_x_dbg :small_red_triangle: 0 - +8 0.0 - 0.0 N/A N/A
arduino:samd:mkrzero :small_red_triangle: 0 - +4 0.0 - 0.0 0 - 0 0.0 - 0.0
Click for full report table Board|examples/CardInfo
flash|%|examples/CardInfo
RAM for global variables|%|examples/Datalogger
flash|%|examples/Datalogger
RAM for global variables|%|examples/DumpFile
flash|%|examples/DumpFile
RAM for global variables|%|examples/Files
flash|%|examples/Files
RAM for global variables|%|examples/NonBlockingWrite
flash|%|examples/NonBlockingWrite
RAM for global variables|%|examples/ReadWrite
flash|%|examples/ReadWrite
RAM for global variables|%|examples/listfiles
flash|%|examples/listfiles
RAM for global variables|% -|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|- arduino:avr:leonardo|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|-10|-0.03|0|0.0 arduino:avr:mega|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|-10|-0.0|0|0.0 arduino:avr:nano|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|-10|-0.03|0|0.0 arduino:mbed_nano:nano33ble|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0 arduino:mbed_nano:nanorp2040connect|0|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0 arduino:mbed_portenta:envie_m4|0|0.0|0|0.0|64|0.01|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0 arduino:mbed_portenta:envie_m7|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|64|0.01|0|0.0|64|0.01|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0 arduino:megaavr:nona4809|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|0|0.0|-10|-0.02|0|0.0 arduino:sam:arduino_due_x_dbg|0|0.0|N/A|N/A|8|0.0|N/A|N/A|8|0.0|N/A|N/A|8|0.0|N/A|N/A|8|0.0|N/A|N/A|8|0.0|N/A|N/A|8|0.0|N/A|N/A arduino:samd:mkrzero|0|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0|4|0.0|0|0.0
Click for full report CSV ``` Board,examples/CardInfo
flash,%,examples/CardInfo
RAM for global variables,%,examples/Datalogger
flash,%,examples/Datalogger
RAM for global variables,%,examples/DumpFile
flash,%,examples/DumpFile
RAM for global variables,%,examples/Files
flash,%,examples/Files
RAM for global variables,%,examples/NonBlockingWrite
flash,%,examples/NonBlockingWrite
RAM for global variables,%,examples/ReadWrite
flash,%,examples/ReadWrite
RAM for global variables,%,examples/listfiles
flash,%,examples/listfiles
RAM for global variables,% arduino:avr:leonardo,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,-10,-0.03,0,0.0 arduino:avr:mega,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,-10,-0.0,0,0.0 arduino:avr:nano,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,-10,-0.03,0,0.0 arduino:mbed_nano:nano33ble,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0 arduino:mbed_nano:nanorp2040connect,0,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0 arduino:mbed_portenta:envie_m4,0,0.0,0,0.0,64,0.01,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0 arduino:mbed_portenta:envie_m7,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,64,0.01,0,0.0,64,0.01,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0 arduino:megaavr:nona4809,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,0,0.0,-10,-0.02,0,0.0 arduino:sam:arduino_due_x_dbg,0,0.0,N/A,N/A,8,0.0,N/A,N/A,8,0.0,N/A,N/A,8,0.0,N/A,N/A,8,0.0,N/A,N/A,8,0.0,N/A,N/A,8,0.0,N/A,N/A arduino:samd:mkrzero,0,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0,4,0.0,0,0.0 ```