Index: branches/2013/dev_r4028_CNRS_LIM3/NEMOGCM/NEMO/OPA_SRC/SBC/sbcice_lim.F90
===================================================================
--- branches/2013/dev_r4028_CNRS_LIM3/NEMOGCM/NEMO/OPA_SRC/SBC/sbcice_lim.F90	(revision 4634)
+++ branches/2013/dev_r4028_CNRS_LIM3/NEMOGCM/NEMO/OPA_SRC/SBC/sbcice_lim.F90	(revision 4649)
@@ -69,4 +69,5 @@
 
    PUBLIC sbc_ice_lim  ! routine called by sbcmod.F90
+   PUBLIC lim_prt_state
    
    !! * Substitutions
@@ -170,5 +171,5 @@
          !
          IF( ln_nicep ) THEN      ! control print at a given point
-            jiindx = 3    ;   jjindx =  49
+            jiindx = 15    ;   jjindx =  44
             IF(lwp) WRITE(numout,*) ' The debugging point is : jiindx : ',jiindx, ' jjindx : ',jjindx
          ENDIF
@@ -183,7 +184,8 @@
          u_oce(:,:) = ssu_m(:,:)                     ! mean surface ocean current at ice velocity point
          v_oce(:,:) = ssv_m(:,:)                     ! (C-grid dynamics :  U- & V-points as the ocean)
-         !
-         t_bo(:,:) = tfreez( sss_m ) +  rt0          ! masked sea surface freezing temperature [Kelvin]
-         !                                           ! (set to rt0 over land)
+
+         ! masked sea surface freezing temperature [Kelvin]
+         t_bo(:,:) = ( tfreez( sss_m ) +  rt0 ) * tmask(:,:,1) + rt0 * ( 1. - tmask(:,:,1) )
+
          CALL albedo_ice( t_su, ht_i, ht_s, zalb_ice_cs, zalb_ice_os )  ! ... ice albedo
 
@@ -310,27 +312,35 @@
          ! salt, heat and mass fluxes
          sfx    (:,:) = 0._wp   ;
-         sfx_bri(:,:) = 0._wp   ;   sfx_dyn(:,:) = 0._wp   ;   sfx_res(:,:) = 0._wp
+         sfx_bri(:,:) = 0._wp   ;   sfx_dyn(:,:) = 0._wp 
          sfx_sni(:,:) = 0._wp   ;   sfx_opw(:,:) = 0._wp
          sfx_bog(:,:) = 0._wp   ;   sfx_dyn(:,:) = 0._wp
          sfx_bom(:,:) = 0._wp   ;   sfx_sum(:,:) = 0._wp
-
-         hfx_thd(:,:) = 0._wp   ;   hfx_dyn(:,:) = 0._wp   ;   hfx_snw(:,:) = 0._wp
-         hfx_tot(:,:) = 0._wp   ;   hfx_spr(:,:) = 0._wp   ;   hfx_res(:,:) = 0._wp
-         hfx_sub(:,:) = 0._wp   ;   hfx_err(:,:) = 0._wp   ;   hfx_in (:,:) = 0._wp   ;   hfx_out(:,:) = 0._wp
-         hfx_err_rem(:,:) = 0._wp
-
-         wfx_snw(:,:) = 0._wp   ;   wfx_ice(:,:) = 0._wp   ;   wfx_sub(:,:) = 0._wp
+         sfx_res(:,:) = 0._wp
+
+         wfx_snw(:,:) = 0._wp   ;   wfx_ice(:,:) = 0._wp
          wfx_sni(:,:) = 0._wp   ;   wfx_opw(:,:) = 0._wp
          wfx_bog(:,:) = 0._wp   ;   wfx_dyn(:,:) = 0._wp
          wfx_bom(:,:) = 0._wp   ;   wfx_sum(:,:) = 0._wp
-         wfx_res(:,:) = 0._wp   ;   
-         !
-         fhld  (:,:) = 0._wp 
-         fmmflx(:,:) = 0._wp     
-         ftr_ice(:,:,:) = 0._wp   ! part of solar radiation transmitted through the ice
+         wfx_res(:,:) = 0._wp   ;   wfx_sub(:,:) = 0._wp
+         wfx_spr(:,:) = 0._wp   ;   
+
+         hfx_in (:,:) = 0._wp   ;   hfx_out(:,:) = 0._wp
+         hfx_thd(:,:) = 0._wp   ;   
+         hfx_snw(:,:) = 0._wp   ;   hfx_opw(:,:) = 0._wp
+         hfx_bog(:,:) = 0._wp   ;   hfx_dyn(:,:) = 0._wp
+         hfx_bom(:,:) = 0._wp   ;   hfx_sum(:,:) = 0._wp
+         hfx_res(:,:) = 0._wp   ;   hfx_sub(:,:) = 0._wp
+         hfx_spr(:,:) = 0._wp   ;   hfx_dif(:,:) = 0._wp 
+         hfx_err(:,:) = 0._wp   ;   hfx_err_rem(:,:) = 0._wp
+
+         !
+         fhld  (:,:)    = 0._wp 
+         fmmflx(:,:)    = 0._wp     
+         ! part of solar radiation transmitted through the ice
+         ftr_ice(:,:,:) = 0._wp
 
          ! diags
-         diag_trp_vi(:,:) = 0._wp  ; diag_trp_vs(:,:) = 0._wp  ;  diag_trp_ei(:,:) = 0._wp  ;  diag_trp_es(:,:) = 0._wp  ; 
-         diag_heat_dhc1(:,:) = 0._wp   ;   
+         diag_trp_vi  (:,:) = 0._wp  ; diag_trp_vs(:,:) = 0._wp  ;  diag_trp_ei(:,:) = 0._wp  ;  diag_trp_es(:,:) = 0._wp
+         diag_heat_dhc(:,:) = 0._wp  
 
          ! dynamical invariants
@@ -820,6 +830,5 @@
                WRITE(numout,*) ' hfx_in       : ', hfx_in(ji,jj)
                WRITE(numout,*) ' hfx_out      : ', hfx_out(ji,jj)
-               WRITE(numout,*) ' hfx_tot      : ', hfx_tot(ji,jj)
-               WRITE(numout,*) ' dhc          : ', diag_heat_dhc1(ji,jj)              
+               WRITE(numout,*) ' dhc          : ', diag_heat_dhc(ji,jj)              
                WRITE(numout,*)
                WRITE(numout,*) ' hfx_dyn      : ', hfx_dyn(ji,jj)
