From 90800f7b5bd94866375821fd23feea45d5bf3f45 Mon Sep 17 00:00:00 2001 From: Salvatore Filippone Date: Thu, 18 Nov 2010 12:34:30 +0000 Subject: [PATCH] psblas3: psi_penv_mod.F90 Modified psb_close so that in serial mode NCTXT gets decremented, to free an ICTXT slot. --- base/modules/psi_penv_mod.F90 | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/base/modules/psi_penv_mod.F90 b/base/modules/psi_penv_mod.F90 index 8fa21adc..b01ad4b9 100644 --- a/base/modules/psi_penv_mod.F90 +++ b/base/modules/psi_penv_mod.F90 @@ -271,7 +271,11 @@ contains ! !$ call psb_error(ictxt) ! !$ endif ! !$ endif -#if !defined(SERIAL_MPI) +#if defined(SERIAL_MPI) + ! Under serial mode, CLOSE has no effect, but reclaim + ! the used ICTXT number. + nctxt = max(0, nctxt - 1) +#else if (close_) then call psb_close_all_context(psb_mesg_queue) else