Skip to content

Commit

Permalink
Minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
jrmaddison committed Sep 20, 2024
1 parent 56f6a1c commit 32bf6a4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tlm_adjoint/fenics/backend_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,10 @@ def add_duplicated_comm(comm, dup_comm):
_dup_comms.setdefault(comm_py2f, {})[dup_comm_py2f] = dup_comm

def comm_finalize_callback(comm_py2f):
_dup_comms.pop(comm_py2f)
_dup_comms.pop(comm_py2f, None)

def dup_comm_finalize_callback(comm_py2f, dup_comm_py2f):
_dup_comms.get(comm_py2f, {}).pop(dup_comm_py2f)
_dup_comms.get(comm_py2f, {}).pop(dup_comm_py2f, None)

comm_finalize(comm, comm_finalize_callback,
comm_py2f)
Expand Down

0 comments on commit 32bf6a4

Please sign in to comment.