Skip to content

Commit

Permalink
keep only 'not' as an alternate
Browse files Browse the repository at this point in the history
  • Loading branch information
frs69wq committed May 24, 2024
1 parent 57105e0 commit 36c13ce
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/FileSystem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ namespace simgrid::fsmod {
throw std::invalid_argument("Invalid partition path");
}
for (auto const &mp: this->partitions_) {
if ((mp.first.rfind(cleanup_mount_point, 0) == 0) or (cleanup_mount_point.rfind(mp.first, 0) == 0)) {
if ((mp.first.rfind(cleanup_mount_point, 0) == 0) || (cleanup_mount_point.rfind(mp.first, 0) == 0)) {
throw std::invalid_argument("Mount point already exists or is prefix of existing mount point");
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/Partition.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ namespace simgrid::fsmod {
if (src_metadata->get_file_refcount() > 0) {
throw FileSystemException(XBT_THROW_POINT, "Cannot move a file that is open");
}
if (dst_metadata and dst_metadata->get_file_refcount()) {
if (dst_metadata && dst_metadata->get_file_refcount()) {
throw FileSystemException(XBT_THROW_POINT, "Cannot move to a destination file that is open");
}

Expand Down

0 comments on commit 36c13ce

Please sign in to comment.