+ setenv(ENV_NAME_PRIVATE_FDS, env, 1 /* overwrite */);
+
+ /* Child processes must use ENV_NAME_PRIVATE_FDS to get the updated list
+ * of tracked file descriptors, not the static list provided by the user
+ * in ENV_NAME_FDS.
+ *
+ * But only remove it if the static list in ENV_NAME_FDS was loaded by
+ * init_from_environment() and merged into ENV_NAME_PRIVATE_FDS. */
+ if (used_fds_set_by_user) {
+ unsetenv(ENV_NAME_FDS);
+ }