@@ -170,18 +170,17 @@ int check_darray_file(int iosysid, int ntasks, int my_rank, char *filename)
170170 if ((ret = PIOc_read_darray (ncid , 0 , ioid , arraylen , & data_in )))
171171 ERR (ret );
172172
173- /* Check data. */
174- printf ("my_rank %d data_in %f\n" ,my_rank , data_in );
175- if (data_in != my_rank * 10 )
176- ERR (ERR_WRONG );
177-
178173 /* Try to write, but this will fail because file was opened with
179174 * NOWRITE. */
180175 float fillvalue = 0.0 ;
181176 float test_data = my_rank * 10 ;
182177 if (PIOc_write_darray (ncid , 0 , ioid , arraylen , & test_data , & fillvalue ) != PIO_EPERM )
183178 ERR (ret );
184179
180+ /* Check data. */
181+ if (data_in != my_rank * 10 )
182+ ERR (ERR_WRONG );
183+
185184 /* Close the file. */
186185 if ((ret = PIOc_closefile (ncid )))
187186 ERR (ret );
@@ -210,7 +209,7 @@ int test_darray(int iosysid, int ioid, int num_flavors, int *flavor, int my_rank
210209 {
211210 /* Create the filename. */
212211 sprintf (filename , "%s_flavor_%d_fv_%d.nc" , TEST_NAME , flavor [fmt ], fv );
213- printf ( "Creating file %s\n" , filename );
212+
214213 /* Create the netCDF output file. */
215214 if ((ret = PIOc_createfile (iosysid , & ncid , & (flavor [fmt ]), filename , PIO_CLOBBER )))
216215 ERR (ret );
@@ -238,17 +237,10 @@ int test_darray(int iosysid, int ioid, int num_flavors, int *flavor, int my_rank
238237 float fillvalue = PIO_FILL_FLOAT ;
239238 float * fillvaluep = fv ? & fillvalue : NULL ;
240239 float test_data [arraylen ];
241- for (int f = 0 ; f < arraylen ; f ++ ){
240+ for (int f = 0 ; f < arraylen ; f ++ )
242241 test_data [f ] = my_rank * 10 + f ;
243- if (flavor [fmt ] == 3 )
244- printf ("my_rank %d test_data[%d]%f\n" ,my_rank , f , test_data [f ]);
245- }
246- if (flavor [fmt ] == 3 )
247- PIOc_set_log_level (3 );
248242 if ((ret = PIOc_write_darray (ncid , varid , ioid , arraylen , test_data , fillvaluep )))
249243 ERR (ret );
250- if (flavor [fmt ] == 3 )
251- PIOc_set_log_level (0 );
252244
253245 /* Close the netCDF file. */
254246 if ((ret = PIOc_closefile (ncid )))
0 commit comments