Commit 28ea173f authored by adelmann's avatar adelmann 🎗
Browse files

Fix problem reported by Matthias w.r.t. setOPALt and setOPALcycl

parent 466d3f63
......@@ -2711,7 +2711,7 @@ bool DataSink::readOneBunch(PartBunch &beam, const string fn_appendix, const siz
*/
bool DataSink::isOPALt() {
char opalFlavour[128];
h5_int64_t rc = H5ReadFileAttribString(H5file_m, "OPAL_flavour", opalFlavour);
h5_int64_t rc = H5ReadStepAttribString(H5file_m, "OPAL_flavour", opalFlavour);
if(rc != H5_SUCCESS)
ERRORMSG("H5 rc= " << rc << " in " << __FILE__ << " @ line " << __LINE__ << endl);
return (std::string(opalFlavour)==std::string("opal-t"));
......@@ -2724,7 +2724,7 @@ bool DataSink::isOPALt() {
*/
void DataSink::setOPALcycl() {
string OPALFlavour("opal-cycl");
h5_int64_t rc = H5WriteFileAttribString(H5file_m, "OPAL_flavour", OPALFlavour.c_str());
h5_int64_t rc = H5WriteStepAttribString(H5file_m, "OPAL_flavour", OPALFlavour.c_str());
if(rc != H5_SUCCESS)
ERRORMSG("H5 rc= " << rc << " in " << __FILE__ << " @ line " << __LINE__ << endl);
}
......@@ -2736,7 +2736,7 @@ void DataSink::setOPALcycl() {
*/
void DataSink::setOPALt() {
string OPALFlavour("opal-t");
h5_int64_t rc = H5WriteFileAttribString(H5file_m, "OPAL_flavour", OPALFlavour.c_str());
h5_int64_t rc = H5WriteStepAttribString(H5file_m, "OPAL_flavour", OPALFlavour.c_str());
if(rc != H5_SUCCESS)
ERRORMSG("H5 rc= " << rc << " in " << __FILE__ << " @ line " << __LINE__ << endl);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment