Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
LEFEBVREJP email
radix
Commits
d31ed681
Commit
d31ed681
authored
Oct 09, 2018
by
Purves, Murray
Browse files
Closing all streams at the end of read/write
parent
b0b373f0
Pipeline
#16171
failed with stages
in 7 minutes and 43 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
radixio/spectrumpcfstream.i.hh
View file @
d31ed681
...
...
@@ -304,6 +304,8 @@ bool SpectrumPCFStream<data_type>::read_from(const std::string &file)
radix_line
(
"PCF file read complete and successful. "
<<
mData
->
spectrumDataCount
()
<<
" spectra read"
);
stream
.
close
();
result
=
true
;
return
result
;
}
...
...
@@ -542,6 +544,8 @@ bool SpectrumPCFStream<data_type>::write_to(const std::string &file) const
radix_line
(
" Spectrum write complete"
);
}
stream
.
close
();
result
=
true
;
return
result
;
}
...
...
radixio/tests/tstSpectrum.cc
View file @
d31ed681
...
...
@@ -78,7 +78,7 @@ TEST(RadixIO, SpectrumToSPE)
ASSERT_TRUE
(
testStream2
.
read_from
(
testWriteSPEFile
));
// Test the contents of the two spectra
EXPECT_EQ
(
30
,
testSpectrum2
->
spectrumDataCount
());
EXPECT_EQ
(
1
,
testSpectrum2
->
spectrumDataCount
());
EXPECT_EQ
(
testSpectrum1
->
spectrumDataCount
(),
testSpectrum2
->
spectrumDataCount
());
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment