schwehr / generic-sensor-format

Sonar Generic Sensor Format (gsf) codec
Other
13 stars 8 forks source link

Use an automatic closer class for GSF files. #82

Open schwehr opened 9 years ago

schwehr commented 9 years ago

For the C++ testing of the GSF C code:

It looks like I'm often not closing files at the end of tests. Need to create a GsfFile class that handles calling gsfClose in the destructor. Also would be good to have a static function that constructs a unique_ptr so that if the open fails, it only gives back a nullptr.