This avoids those being inherited by the childs. Closes: #471488
+2008-06-04 Guillem Jover <guillem@debian.org>
+
+ * src/main.c (setpipe): Set file descriptors to close on exec.
+
2008-06-04 Guillem Jover <guillem@debian.org>
* dpkg-deb/build.c (getfi): Use m_realloc instead of realloc.
* Fix the support for passing more than one --status-fd option to dpkg.
Until now only the last one was being used.
* Replace realloc plus error checking usage with m_realloc.
+ * Close --status-fd file descriptors on exec, so that they are not
+ inherited by the childs. Closes: #471488
[ Raphael Hertzog ]
* Enhance dpkg-shlibdeps's error message when a library can't be found to
if (*ep || v > INT_MAX)
badusage(_("invalid integer for --%s: `%.250s'"),cip->olong,value);
+ setcloexec(v, _("<package status and progress file descriptor>"));
+
pipe_new = nfmalloc(sizeof(struct pipef));
pipe_new->fd = v;
pipe_new->next = *pipe_head;