collapse if statement in datastore
This commit is contained in:
parent
3568dc2083
commit
36c0edea2a
@ -63,9 +63,7 @@ typedef StaticGraph<QueryEdge::EdgeData> QueryGraph;
|
|||||||
// delete a shared memory region. report warning if it could not be deleted
|
// delete a shared memory region. report warning if it could not be deleted
|
||||||
void delete_region(const SharedDataType region)
|
void delete_region(const SharedDataType region)
|
||||||
{
|
{
|
||||||
if (SharedMemory::RegionExists(region))
|
if (SharedMemory::RegionExists(region) && !SharedMemory::Remove(region))
|
||||||
{
|
|
||||||
if (!SharedMemory::Remove(region))
|
|
||||||
{
|
{
|
||||||
const std::string name = [&]
|
const std::string name = [&]
|
||||||
{
|
{
|
||||||
@ -90,7 +88,6 @@ void delete_region(const SharedDataType region)
|
|||||||
|
|
||||||
SimpleLogger().Write(logWARNING) << "could not delete shared memory region " << name;
|
SimpleLogger().Write(logWARNING) << "could not delete shared memory region " << name;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// find all existing shmem regions and remove them.
|
// find all existing shmem regions and remove them.
|
||||||
|
Loading…
Reference in New Issue
Block a user