Index: LMDZ6/trunk/libf/dyn3d/conf_gcm.F90
===================================================================
--- LMDZ6/trunk/libf/dyn3d/conf_gcm.F90	(revision 3435)
+++ LMDZ6/trunk/libf/dyn3d/conf_gcm.F90	(revision 3540)
@@ -21,5 +21,5 @@
   USE serre_mod, ONLY: clon,clat,grossismx,grossismy,dzoomx,dzoomy, &
                        alphax,alphay,taux,tauy
-  USE temps_mod, ONLY: calend
+  USE temps_mod, ONLY: calend, year_len
 
   IMPLICIT NONE
@@ -115,4 +115,14 @@
   calend = 'earth_360d'
   CALL getin('calend', calend)
+! initialize year_len for aquaplanets and 1D
+      if (calend == 'earth_360d') then
+        year_len=360
+      else if (calend == 'earth_365d') then
+        year_len=365
+      else if (calend == 'earth_366d') then
+        year_len=366
+      else 
+        year_len=1
+      endif
 
   !Config  Key  = dayref
Index: LMDZ6/trunk/libf/dyn3d/temps_mod.F90
===================================================================
--- LMDZ6/trunk/libf/dyn3d/temps_mod.F90	(revision 3435)
+++ LMDZ6/trunk/libf/dyn3d/temps_mod.F90	(revision 3540)
@@ -13,4 +13,5 @@
   INTEGER   annee_ref
   INTEGER   day_ref
+  INTEGER   year_len
   REAL      dt ! (dynamics) time step (changes if doing Matsuno or LF step)
   REAL      jD_ref ! reference julian day date (beginning of experiment)
