diff options
| author | Pieter Wuille <[email protected]> | 2014-08-01 22:57:55 +0200 |
|---|---|---|
| committer | Pieter Wuille <[email protected]> | 2014-08-09 01:43:23 +0200 |
| commit | eb0b56b19017ab5c16c745e6da39c53126924ed6 (patch) | |
| tree | 3d59b76170293cebb37b57fd7669faf7f333623c /src/test/script_tests.cpp | |
| parent | Merge branch 'merge-rawtx2' into merge-rawtx3 (diff) | |
| download | discoin-eb0b56b19017ab5c16c745e6da39c53126924ed6.tar.xz discoin-eb0b56b19017ab5c16c745e6da39c53126924ed6.zip | |
Simplify serialize.h's exception handling
Remove the 'state' and 'exceptmask' from serialize.h's stream implementations,
as well as related methods.
As exceptmask always included 'failbit', and setstate was always called with
bits = failbit, all it did was immediately raise an exception. Get rid of
those variables, and replace the setstate with direct exception throwing
(which also removes some dead code).
As a result, good() is never reached after a failure (there are only 2
calls, one of which is in tests), and can just be replaced by !eof().
fail(), clear(n) and exceptions() are just never called. Delete them.
Diffstat (limited to 'src/test/script_tests.cpp')
0 files changed, 0 insertions, 0 deletions