tags 320925 patch
thanks

I have made a patch that sets close-on-exec. Tell me if this is what
you expected, and if my patch really fixes what you meant.
Also please test if dpkg still works correctly
diff -Nru ./intl/log.c ../dpkg-1.13.11/intl/log.c
--- ./intl/log.c	2005-06-06 07:33:19.000000000 +0300
+++ ../dpkg-1.13.11/intl/log.c	2005-08-05 17:45:04.614609099 +0300
@@ -76,9 +76,10 @@
       if (last_logfilename == NULL)
 	return;
       strcpy (last_logfilename, logfilename);
       last_logfile = fopen (logfilename, "a");
       if (last_logfile == NULL)
 	return;
+      fcntl(fileno(last_logfile),F_SETFD,FD_CLOEXEC);//set close-on-exec flag
     }
   logfile = last_logfile;
diff -Nru ./debian/changelog ../dpkg-1.13.11/debian/changelog
--- ./debian/changelog	2005-06-28 16:19:08.000000000 +0300
+++ ../dpkg-1.13.11/debian/changelog	2005-08-05 17:47:38.934071447 +0300
@@ -1,3 +1,8 @@
+dpkg (1.13.11) unstable; urgency=low
+
+  * set close-on-exec flag for logfile: intl/log.c. Fixes: 320925
+ -- root <[EMAIL PROTECTED]>  Fri,  5 Aug 2005 17:46:33 +0300
+
 dpkg (1.13.10) unstable; urgency=low
   
   The "Bully's Special Prize" Release.

Reply via email to