leeres plottyfile wirft exception
This commit is contained in:
parent
198feef12f
commit
22a5b466db
7 changed files with 492 additions and 1 deletions
|
@ -146,6 +146,9 @@ void PlottyFile::prepStr(std::string& str, uint8_t len)
|
|||
|
||||
void PlottyFile::writeToFile(std::string filename)
|
||||
{
|
||||
if(dots.empty())
|
||||
throw std::length_error("Es wurden keine Punkte gespeichert.");
|
||||
|
||||
prepStr(unit_x, STR_LEN_SHORT);
|
||||
prepStr(desc_x, STR_LEN_LARGE);
|
||||
prepStr(unit_y, STR_LEN_SHORT);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue