mirror of https://github.com/QMCPACK/qmcpack.git
fix the wrong communicator in writing *.bandinfo.dat when running ensemble jobs.
hdf_archive::open no longer creates files when it tries to open non existing files. git-svn-id: https://subversion.assembla.com/svn/qmcdev/trunk@6725 e5b18d87-469d-4833-9cc0-8cdfa06e9491
This commit is contained in:
parent
3a2a2000a3
commit
29f55503c1
|
@ -196,7 +196,7 @@ namespace qmcplusplus
|
|||
}
|
||||
|
||||
//write to a file
|
||||
const Communicate* comm=OHMMS::Controller;
|
||||
const Communicate* comm=myComm;
|
||||
if(comm->rank()) return;
|
||||
|
||||
string aname= make_bandinfo_filename(mybuilder->getName(),spin
|
||||
|
|
|
@ -97,8 +97,8 @@ bool hdf_archive::open(const std::string& fname,unsigned flags)
|
|||
return true;
|
||||
close();
|
||||
file_id = H5Fopen(fname.c_str(),flags,access_id);
|
||||
if(file_id==is_closed)
|
||||
file_id = H5Fcreate(fname.c_str(),flags,H5P_DEFAULT,access_id);
|
||||
// if(file_id==is_closed)
|
||||
// file_id = H5Fcreate(fname.c_str(),flags,H5P_DEFAULT,access_id);
|
||||
return file_id != is_closed;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue