[PATCH] system-cancel part2

2003-01-15 Thread Thomas Pfaff
This patch will make sure that the signal handlers that are saved in the system call are restored even if the thread got cancelled. Since spawn_guts uses waitpid when mode is _P_WAIT spawn_guts is a cancellation point. Attached is the patch and a new test case. 2003-01-15 Thomas Paff <[EMAIL P

Re: [PATCH] system-cancel part2

2003-01-15 Thread Robert Collins
On Wed, 2003-01-15 at 22:23, Thomas Pfaff wrote: > This patch will make sure that the signal handlers that are saved in the > system call are restored even if the thread got cancelled. Since > spawn_guts uses waitpid when mode is _P_WAIT spawn_guts is a cancellation > point. > > Attached is the pa

Re: [PATCH] system-cancel part2

2003-01-15 Thread Thomas Pfaff
On Wed, 15 Jan 2003, Robert Collins wrote: > On Wed, 2003-01-15 at 22:23, Thomas Pfaff wrote: > > This patch will make sure that the signal handlers that are saved in the > > system call are restored even if the thread got cancelled. Since > > spawn_guts uses waitpid when mode is _P_WAIT spawn_g

Re: setuid on Win95 and etc_changed, passwd & group.

2003-01-15 Thread Pierre A. Humblet
Christopher Faylor wrote: > >During testing I noticed another issue. If etc_changed is initialized > >in a parent and /etc/passwd is changed between the moments where a > >child is forked and where etc_changed is first called in the child, > >etc_changed unexpectedly returns false in the child (Wi

Re: [PATCH] system-cancel part2

2003-01-15 Thread Christopher Faylor
On Wed, Jan 15, 2003 at 12:23:14PM +0100, Thomas Pfaff wrote: > >This patch will make sure that the signal handlers that are saved in the >system call are restored even if the thread got cancelled. Since >spawn_guts uses waitpid when mode is _P_WAIT spawn_guts is a cancellation >point. > >Attached

Where to put my basename() and dirname() implementation...

2003-01-15 Thread Elfyn McBratney
I have finished my basename() and dirname() (so long for something so simple ;-) implementation and I have two questions: 1) Where would be the best place to put these functions? I was thinking dir.cc or path.cc? 2) What header file (winsup/cygwin/include) should I put the prototypes into? On my s

Re: Where to put my basename() and dirname() implementation...

2003-01-15 Thread Elfyn McBratney
Doooh! Thanks for the heads up Sergey. It kinda seems pointless just adding a dirname() function but what the hell... Any inkling where i should put this lone sub? Elfyn [EMAIL PROTECTED] - Original Message - From: "Sergey Okhapkin" <[EMAIL PROTECTED]> To: "'Elfyn McBratney'" <[EMAIL PROT

Re: setuid on Win95 and etc_changed, passwd & group.

2003-01-15 Thread Christopher Faylor
On Wed, Jan 15, 2003 at 09:31:25AM -0500, Pierre A. Humblet wrote: >Christopher Faylor wrote: >> I'm not sure what you're saying. Are you saying it's inefficient >> because it is duplicated? I don't see anything wrong with the code. > >I believe there are 8 unused bytes in every block. >On line 2

Re: Where to put my basename() and dirname() implementation...

2003-01-15 Thread Christopher Faylor
On Wed, Jan 15, 2003 at 06:04:06PM -, Elfyn McBratney wrote: >Doooh! Thanks for the heads up Sergey. It kinda seems pointless just adding >a dirname() function but what the hell... Any inkling where i should put >this lone sub? I don't want to add any more libiberty routines to cygwin since th

NT 4.0 fixup_mmaps_after_fork() patch

2003-01-15 Thread Jason Tishler
It appears that ReadProcessMemory() can fail with ERROR_NOACCESS under NT 4.0. See attached patch. BTW, my mmap-test test case works under NT 4.0 without this patch. However, vsFTPd does not. Go figure! Thanks, Jason -- PGP/GPG Key: http://www.tishler.net/jason/pubkey.asc or key servers Finge

Re: setuid on Win95 and etc_changed, passwd & group.

2003-01-15 Thread Pierre A. Humblet
Christopher Faylor wrote: > > Ok. Got it. I checked in a patch. > Chris, In a similar same vein, class fhandler_base has a member open_status that is set in a dozen places but never read, AFAICT. I was thinking that those patches would get into 1.3.20 but making etc_changed non heritable migh

Re: setuid on Win95 and etc_changed, passwd & group.

2003-01-15 Thread Christopher Faylor
On Wed, Jan 15, 2003 at 02:32:50PM -0500, Pierre A. Humblet wrote: >Christopher Faylor wrote: >> >> Ok. Got it. I checked in a patch. >> >Chris, > >In a similar same vein, class fhandler_base has a member open_status >that is set in a dozen places but never read, AFAICT. Funny, I just noticed

Re: [PATCH] system-cancel part2

2003-01-15 Thread Robert Collins
On Thu, 2003-01-16 at 00:19, Thomas Pfaff wrote: > On Wed, 15 Jan 2003, Robert Collins wrote: > The test case was created to prove that system is a cancellation point > even if the child process is already created and the system call is > waiting on child termination. Thank you for the new test c

Re: Where to put my basename() and dirname() implementation...

2003-01-15 Thread Charles Wilson
Christopher Faylor wrote: I don't want to add any more libiberty routines to cygwin since the licensing is suspect. So, please follow the normal submission rules. Probably miscfuncs.cc is the place to add this. That make sense. Unlike many of the other functions in libiberty, The basename(

Re: setuid on Win95 and etc_changed, passwd & group.

2003-01-15 Thread Christopher Faylor
On Wed, Jan 15, 2003 at 03:06:07PM -0500, Christopher Faylor wrote: >On Wed, Jan 15, 2003 at 02:32:50PM -0500, Pierre A. Humblet wrote: >>Christopher Faylor wrote: >>> >>> Ok. Got it. I checked in a patch. >>> >>Chris, >> >>In a similar same vein, class fhandler_base has a member open_status >>

Re: Where to put my basename() and dirname() implementation...

2003-01-15 Thread Elfyn McBratney
Sorry I'm still at work and my source is at home so as soon as I get home I will send off this magical patch. While on the topic of copyright assignment would this be required? The patch adds about 40-50 lines... Elfyn [EMAIL PROTECTED] - Original Message - From: "Charles Wilson" <[EMAIL

Re: Where to put my basename() and dirname() implementation...

2003-01-15 Thread Christopher Faylor
On Wed, Jan 15, 2003 at 03:21:47PM -0500, Charles Wilson wrote: >Christopher Faylor wrote: > >> >>I don't want to add any more libiberty routines to cygwin since the >>licensing is suspect. So, please follow the normal submission rules. >>Probably miscfuncs.cc is the place to add this. >> > >That

Re: Where to put my basename() and dirname() implementation...

2003-01-15 Thread Christopher Faylor
On Wed, Jan 15, 2003 at 08:28:54PM -, Elfyn McBratney wrote: >Sorry I'm still at work and my source is at home so as soon as I get home I >will send off this magical patch. > >While on the topic of copyright assignment would this be required? The patch >adds about 40-50 lines... Yes, a copyrig

etc_changed, passwd & group.

2003-01-15 Thread Pierre A. Humblet
Chris, Here is the code as it stands. It compiles & runs, and passes fork tests correctly. Feel free to takeover or at least have a look. I will continue testing tomorrow evening. I include only the 5 files that are related to etc_changed, the 5 others (setuid on Win9X) can wait. Pierre P.S. Do