sat: catch write errors
* src/tgbaalgos/dtbasat.cc, src/tgbaalgos/dtgbasat.cc: Throw exceptions on write errors.
This commit is contained in:
parent
1f3b7e8002
commit
22f944ad56
2 changed files with 4 additions and 0 deletions
|
|
@ -660,6 +660,7 @@ namespace spot
|
|||
#if DEBUG
|
||||
std::fstream out("dtba-sat.dbg",
|
||||
std::ios_base::trunc | std::ios_base::out);
|
||||
out.exceptions(std::ifstream::failbit | std::ifstream::badbit);
|
||||
std::set<int> positive;
|
||||
#endif
|
||||
|
||||
|
|
@ -774,6 +775,7 @@ namespace spot
|
|||
cnf = create_tmpfile("dtba-sat-", ".cnf");
|
||||
std::fstream cnfs(cnf->name(),
|
||||
std::ios_base::trunc | std::ios_base::out);
|
||||
cnfs.exceptions(std::ifstream::failbit | std::ifstream::badbit);
|
||||
dtba_to_sat(cnfs, a, *current, state_based);
|
||||
cnfs.close();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -869,6 +869,7 @@ namespace spot
|
|||
#if DEBUG
|
||||
std::fstream out("dtgba-sat.dbg",
|
||||
std::ios_base::trunc | std::ios_base::out);
|
||||
out.exceptions(std::ifstream::failbit | std::ifstream::badbit);
|
||||
std::set<int> positive;
|
||||
#endif
|
||||
|
||||
|
|
@ -982,6 +983,7 @@ namespace spot
|
|||
cnf = create_tmpfile("dtgba-sat-", ".cnf");
|
||||
std::fstream cnfs(cnf->name(),
|
||||
std::ios_base::trunc | std::ios_base::out);
|
||||
cnfs.exceptions(std::ifstream::failbit | std::ifstream::badbit);
|
||||
dtgba_to_sat(cnfs, a, *current, state_based);
|
||||
cnfs.close();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue