Added a stanza to not copy _NCProperties atttribute from an old file to a new file, and instead use the properties appropriate for the newly created file.
@@ -1199,6 +1199,9 @@ copy_atts(int igrp, int ivar, int ogrp, int ovar)
for(iatt = 0; iatt < natts; iatt++) {
char name[NC_MAX_NAME];
NC_CHECK(nc_inq_attname(igrp, ivar, iatt, name));
+ if(!strcmp(name,"_NCProperties"))
+ return stat;
+
NC_CHECK(nc_copy_att(igrp, ivar, name, ogrp, ovar));
}
return stat;
