Index: palm/trunk/SOURCE/diagnostic_output_quantities_mod.f90
===================================================================
--- palm/trunk/SOURCE/diagnostic_output_quantities_mod.f90	(revision 4457)
+++ palm/trunk/SOURCE/diagnostic_output_quantities_mod.f90	(revision 4517)
@@ -110,4 +110,5 @@
                data_output,                                                    &
                message_string,                                                 &
+               restart_data_format_output,                                     &
                varnamelength
 !
@@ -1942,4 +1943,5 @@
 !> Note: With the current structure reading of non-standard array is not
 !> possible
+!> COMMENT:  these arrays should be given standard index bounds! (Siggi)
 !------------------------------------------------------------------------------!
 !  SUBROUTINE doq_rrd_local( k, nxlf, nxlc, nxl_on_file, nxrf, nxrc,             &
@@ -2048,69 +2050,77 @@
     IMPLICIT NONE
 
-    IF ( ALLOCATED( pt_2m_av ) )  THEN
-       CALL wrd_write_string( 'pt_2m_av' )
-       WRITE ( 14 )  pt_2m_av
+    IF ( TRIM( restart_data_format_output ) == 'fortran_binary' )  THEN
+
+       IF ( ALLOCATED( pt_2m_av ) )  THEN
+          CALL wrd_write_string( 'pt_2m_av' )
+          WRITE ( 14 )  pt_2m_av
+       ENDIF
+
+       IF ( ALLOCATED( ti_av ) )  THEN
+          CALL wrd_write_string( 'ti_av' )
+          WRITE ( 14 )  ti_av
+       ENDIF
+
+       IF ( ALLOCATED( uu_av ) )  THEN
+          CALL wrd_write_string( 'uu_av' )
+          WRITE ( 14 )  uu_av
+       ENDIF
+
+       IF ( ALLOCATED( uv_10m_av ) )  THEN
+          CALL wrd_write_string( 'uv_10m_av' )
+          WRITE ( 14 )  uv_10m_av
+       ENDIF
+
+       IF ( ALLOCATED( vv_av ) )  THEN
+          CALL wrd_write_string( 'vv_av' )
+          WRITE ( 14 )  vv_av
+       ENDIF
+
+       IF ( ALLOCATED( ww_av ) )  THEN
+          CALL wrd_write_string( 'ww_av' )
+          WRITE ( 14 )  ww_av
+       ENDIF
+
+       IF ( ALLOCATED( wu_av ) )  THEN
+          CALL wrd_write_string( 'wu_av' )
+          WRITE ( 14 )  wu_av
+       ENDIF
+
+       IF ( ALLOCATED( wv_av ) )  THEN
+          CALL wrd_write_string( 'wv_av' )
+          WRITE ( 14 )  wv_av
+       ENDIF
+
+       IF ( ALLOCATED( wtheta_av ) )  THEN
+          CALL wrd_write_string( 'wtheta_av' )
+          WRITE ( 14 )  wtheta_av
+       ENDIF
+
+       IF ( ALLOCATED( wq_av ) )  THEN
+          CALL wrd_write_string( 'wq_av' )
+          WRITE ( 14 )  wq_av
+       ENDIF
+
+       IF ( ALLOCATED( wspeed_av ) )  THEN
+          CALL wrd_write_string( 'wspeed_av' )
+          WRITE ( 14 )  wspeed_av
+       ENDIF
+
+       IF ( ALLOCATED( u_center_av ) )  THEN
+          CALL wrd_write_string( 'u_center_av' )
+          WRITE ( 14 )  u_center_av
+       ENDIF
+
+       IF ( ALLOCATED( v_center_av ) )  THEN
+          CALL wrd_write_string( 'v_center_av' )
+          WRITE ( 14 )  v_center_av
+       ENDIF
+
+    ELSEIF ( TRIM( restart_data_format_output ) == 'mpi' )  THEN
+
+       STOP 'mpi-io for doq_wrd_local not realized'
+
     ENDIF
 
-    IF ( ALLOCATED( ti_av ) )  THEN
-       CALL wrd_write_string( 'ti_av' )
-       WRITE ( 14 )  ti_av
-    ENDIF
-
-    IF ( ALLOCATED( uu_av ) )  THEN
-       CALL wrd_write_string( 'uu_av' )
-       WRITE ( 14 )  uu_av
-    ENDIF
-
-    IF ( ALLOCATED( uv_10m_av ) )  THEN
-       CALL wrd_write_string( 'uv_10m_av' )
-       WRITE ( 14 )  uv_10m_av
-    ENDIF
-
-    IF ( ALLOCATED( vv_av ) )  THEN
-       CALL wrd_write_string( 'vv_av' )
-       WRITE ( 14 )  vv_av
-    ENDIF
-
-    IF ( ALLOCATED( ww_av ) )  THEN
-       CALL wrd_write_string( 'ww_av' )
-       WRITE ( 14 )  ww_av
-    ENDIF
-
-    IF ( ALLOCATED( wu_av ) )  THEN
-       CALL wrd_write_string( 'wu_av' )
-       WRITE ( 14 )  wu_av
-    ENDIF
-
-    IF ( ALLOCATED( wv_av ) )  THEN
-       CALL wrd_write_string( 'wv_av' )
-       WRITE ( 14 )  wv_av
-    ENDIF
-
-    IF ( ALLOCATED( wtheta_av ) )  THEN
-       CALL wrd_write_string( 'wtheta_av' )
-       WRITE ( 14 )  wtheta_av
-    ENDIF
-
-    IF ( ALLOCATED( wq_av ) )  THEN
-       CALL wrd_write_string( 'wq_av' )
-       WRITE ( 14 )  wq_av
-    ENDIF
-
-    IF ( ALLOCATED( wspeed_av ) )  THEN
-       CALL wrd_write_string( 'wspeed_av' )
-       WRITE ( 14 )  wspeed_av
-    ENDIF
-
-    IF ( ALLOCATED( u_center_av ) )  THEN
-       CALL wrd_write_string( 'u_center_av' )
-       WRITE ( 14 )  u_center_av
-    ENDIF
-
-    IF ( ALLOCATED( v_center_av ) )  THEN
-       CALL wrd_write_string( 'v_center_av' )
-       WRITE ( 14 )  v_center_av
-    ENDIF
-
  END SUBROUTINE doq_wrd_local
 
