Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Podhorszki, Norbert
ADIOS2
Commits
bcb9cfc8
Commit
bcb9cfc8
authored
Mar 03, 2020
by
Nick
Browse files
Use pre-existing tools to detect file existence.
parent
6305992f
Changes
2
Hide whitespace changes
Inline
Side-by-side
source/adios2/core/ADIOS.cpp
View file @
bcb9cfc8
...
...
@@ -17,6 +17,7 @@
#include
"adios2/core/IO.h"
#include
"adios2/helper/adiosCommDummy.h"
#include
"adios2/helper/adiosFunctions.h"
//InquireKey, BroadcastFile
#include
<adios2sys/SystemTools.hxx>
// OPERATORS
...
...
@@ -65,8 +66,7 @@ ADIOS::ADIOS(const std::string configFile, helper::Comm comm,
{
if
(
!
configFile
.
empty
())
{
std
::
ifstream
f
(
configFile
.
c_str
());
if
(
!
f
.
good
())
if
(
!
adios2sys
::
SystemTools
::
FileExists
(
configFile
))
{
throw
std
::
logic_error
(
"Config file "
+
configFile
+
" passed to ADIOS does not exist."
);
...
...
testing/adios2/engine/bp/TestBPNoXMLRecovery.cpp
View file @
bcb9cfc8
...
...
@@ -10,10 +10,8 @@ int main(int argc, char *argv[])
{
int
rank
=
0
;
#ifdef ADIOS2_HAVE_MPI
int
size
=
1
;
MPI_Init
(
&
argc
,
&
argv
);
MPI_Comm_rank
(
MPI_COMM_WORLD
,
&
rank
);
MPI_Comm_size
(
MPI_COMM_WORLD
,
&
size
);
#endif
adios2
::
ADIOS
ad
;
try
...
...
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