sahrk / DGGRID

A command-line application that generates and manipulates icosahedral discrete global grids.
GNU Affero General Public License v3.0
78 stars 26 forks source link

Fix fallthrough in DgOutShapefile #44

Closed r-barnes closed 2 years ago

r-barnes commented 3 years ago

Fixes:

/home/rick/projects/dggridR/src/src/DgOutShapefile.cpp: In member function ‘void DgOutShapefile::writeDbf(const string&)’:
/home/rick/projects/dggridR/src/src/DgOutShapefile.cpp:243:24: warning: this statement may fall through [-Wimplicit-fallthrough=]
  243 |                ::report("DgOutShapefile::writeDbf() logical shapefile "
      |                ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  244 |                    "attributes not supported", failLevel());
      |                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

I think failLevel() causes the code to quit here. Adding a break eliminates the warning.

r-barnes commented 2 years ago

@sahrk : I've updated to remove the default case.

sahrk commented 2 years ago

Thanks @r-barnes.