diff --git a/ChangeLog b/ChangeLog index 6cd3e71f0b444ea91e918a00135bb8c7126c7cae..e6dcc1b445401b3aba6e841f6a7f664a42bd987e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2024-10-19 Uwe Schulzweida + + * added support for non-thread-safe NetCDF4/HDF5 library + 2024-10-18 Uwe Schulzweida * setpartabn: convert parameter failed (bug fix) diff --git a/NEWS b/NEWS index 19f869799acb35c27a7a9116436d3e89662e1d02..6e1c87c605151a45821210d30acba4ad6f2c6922 100644 --- a/NEWS +++ b/NEWS @@ -6,10 +6,13 @@ Improvement Version 2.5.0 (21 Oct 2024): New features: + * Added support for non-thread-safe NetCDF4/HDF5 library * Remapstat: added support for unstructured target grids * Timselstat: added support for parameter nskip=-1 New operators: Fixed bugs: + * setpartabn: convert parameter failed + * ydrunpctl: parameter pm=r8 failed Version 2.4.4 (18 Sep 2024): diff --git a/src/cdo_settings.cc b/src/cdo_settings.cc index a0612b8659fa619a2a553f8ec8b922b92e25ccae..98c00d1b9671f5fdacbb2ec37b0115b2876b38ec 100644 --- a/src/cdo_settings.cc +++ b/src/cdo_settings.cc @@ -98,7 +98,7 @@ set_cdi_options() fprintf(stderr, "\n"); } - if (Options::test) cdiDefGlobal("THREADSAFE", 1); + if (Threading::cdoLockIO == false) cdiDefGlobal("THREADSAFE", 1); if (Options::CMOR_Mode) cdiDefGlobal("CMOR_MODE", Options::CMOR_Mode); // TODO maybe reposition into effect of "cmor" if (Options::CDO_Reduce_Dim) cdiDefGlobal("REDUCE_DIM", Options::CDO_Reduce_Dim); diff --git a/src/fileStream.cc b/src/fileStream.cc index 849dbc4e494a4d3beef3691d318de21be5eb9859..568efc10ead49871e53023ece9ebde2d9f2458c7 100644 --- a/src/fileStream.cc +++ b/src/fileStream.cc @@ -82,7 +82,7 @@ FileStream::open_write(int p_filetype) if (rstatus != -1) query_user_exit(m_name); } if (p_filetype == CDI_UNDEFID) p_filetype = CDI_FILETYPE_GRB; - + /* #ifndef HAVE_NC4HDF5_THREADSAFE auto outputFileTypeIsNetCDF4 = (p_filetype == CDI_FILETYPE_NC4 || p_filetype == CDI_FILETYPE_NC4C); if (inputFileTypeIsNetCDF4 && outputFileTypeIsNetCDF4 && get_process_num() > 1 && Threading::cdoLockIO == false) @@ -91,7 +91,7 @@ FileStream::open_write(int p_filetype) cdo_warning("Use a thread-safe NetCDF4/HDF5 library or the CDO option -L to avoid such errors."); } #endif - + */ // TODO FIX THIS: if (FileStream::timersEnabled()) cdo::writeTimer.start(); open_lock();