Re: svn commit: r242283 - stable/9/sys/kern

2012-10-28 Thread Eitan Adler
On 29 October 2012 00:46, Eitan Adler  wrote:
> On 29 October 2012 00:32, Konstantin Belousov  wrote:
>> On Mon, Oct 29, 2012 at 03:52:19AM +, Eitan Adler wrote:
>>> Author: eadler
>>> Date: Mon Oct 29 03:52:18 2012
>>> New Revision: 242283
>>> URL: http://svn.freebsd.org/changeset/base/242283
>>>
>>> Log:
>>>   MFC r241855,r241859:
>>>   Update the kill(2) and killpg(2) man pages to the modern permission
>>>   checks. Also indicate killpg(2) is POSIX compliant.
>>>
>>>   Correct the killpg(2) return values:
>>>
>>>   Return EPERM if processes were found but they
>>>   were unable to be signaled.
>>>
>>>   Return the first error from p_cansignal if no signal was successful.
>>>
>>>   Discussed with: jilles
>>>   Approved by:cperciva (implicit)
>>>
>>> Modified:
>>>   stable/9/sys/kern/kern_sig.c
>>> Directory Properties:
>>>   stable/9/sys/   (props changed)
>
>> According to svn mail, r241855 was not merged.
>
> Okay, this is weird. I am certain my original merge command included
> both revisions. Looking at the email it is clear that the
> documentation was not MFCed.
>
> If I attempt to MFC again now I see no changes.
>
> %svn merge -c241855 svn+ssh://svn.freebsd.org/base//head/sys stable9/sys
> %svn status stable9
> %svn diff stable9
> %
>
> What did I do wrong?

Ah! I see.

I forgot that the manual pages are not in the same directory and that
I need to merge to lib/libc as well. I shall fix now.

-- 
Eitan Adler
Source, Ports, Doc committer
Bugmeister, Ports Security teams
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


Re: svn commit: r242283 - stable/9/sys/kern

2012-10-28 Thread Eitan Adler
On 29 October 2012 00:32, Konstantin Belousov  wrote:
> On Mon, Oct 29, 2012 at 03:52:19AM +, Eitan Adler wrote:
>> Author: eadler
>> Date: Mon Oct 29 03:52:18 2012
>> New Revision: 242283
>> URL: http://svn.freebsd.org/changeset/base/242283
>>
>> Log:
>>   MFC r241855,r241859:
>>   Update the kill(2) and killpg(2) man pages to the modern permission
>>   checks. Also indicate killpg(2) is POSIX compliant.
>>
>>   Correct the killpg(2) return values:
>>
>>   Return EPERM if processes were found but they
>>   were unable to be signaled.
>>
>>   Return the first error from p_cansignal if no signal was successful.
>>
>>   Discussed with: jilles
>>   Approved by:cperciva (implicit)
>>
>> Modified:
>>   stable/9/sys/kern/kern_sig.c
>> Directory Properties:
>>   stable/9/sys/   (props changed)

> According to svn mail, r241855 was not merged.

Okay, this is weird. I am certain my original merge command included
both revisions. Looking at the email it is clear that the
documentation was not MFCed.

If I attempt to MFC again now I see no changes.

%svn merge -c241855 svn+ssh://svn.freebsd.org/base//head/sys stable9/sys
%svn status stable9
%svn diff stable9
%

What did I do wrong?


-- 
Eitan Adler
Source, Ports, Doc committer
Bugmeister, Ports Security teams
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"


Re: svn commit: r242283 - stable/9/sys/kern

2012-10-28 Thread Konstantin Belousov
On Mon, Oct 29, 2012 at 03:52:19AM +, Eitan Adler wrote:
> Author: eadler
> Date: Mon Oct 29 03:52:18 2012
> New Revision: 242283
> URL: http://svn.freebsd.org/changeset/base/242283
> 
> Log:
>   MFC r241855,r241859:
>   Update the kill(2) and killpg(2) man pages to the modern permission
>   checks. Also indicate killpg(2) is POSIX compliant.
>   
>   Correct the killpg(2) return values:
>   
>   Return EPERM if processes were found but they
>   were unable to be signaled.
>   
>   Return the first error from p_cansignal if no signal was successful.
>   
>   Discussed with: jilles
>   Approved by:cperciva (implicit)
> 
> Modified:
>   stable/9/sys/kern/kern_sig.c
> Directory Properties:
>   stable/9/sys/   (props changed)
According to svn mail, r241855 was not merged.

> 
> Modified: stable/9/sys/kern/kern_sig.c
> ==
> --- stable/9/sys/kern/kern_sig.c  Mon Oct 29 03:52:18 2012
> (r242282)
> +++ stable/9/sys/kern/kern_sig.c  Mon Oct 29 03:52:18 2012
> (r242283)
> @@ -1599,8 +1599,10 @@ killpg1(struct thread *td, int sig, int 
>  {
>   struct proc *p;
>   struct pgrp *pgrp;
> - int nfound = 0;
> + int err;
> + int ret;
>  
> + ret = ESRCH;
>   if (all) {
>   /*
>* broadcast
> @@ -1613,11 +1615,14 @@ killpg1(struct thread *td, int sig, int 
>   PROC_UNLOCK(p);
>   continue;
>   }
> - if (p_cansignal(td, p, sig) == 0) {
> - nfound++;
> + err = p_cansignal(td, p, sig);
> + if (err == 0) {
>   if (sig)
>   pksignal(p, sig, ksi);
> + ret = err;
>   }
> + else if (ret == ESRCH)
> + ret = err;
>   PROC_UNLOCK(p);
>   }
>   sx_sunlock(&allproc_lock);
> @@ -1644,16 +1649,19 @@ killpg1(struct thread *td, int sig, int 
>   PROC_UNLOCK(p);
>   continue;
>   }
> - if (p_cansignal(td, p, sig) == 0) {
> - nfound++;
> + err = p_cansignal(td, p, sig);
> + if (err == 0) {
>   if (sig)
>   pksignal(p, sig, ksi);
> + ret = err;
>   }
> + else if (ret == ESRCH)
> + ret = err;
>   PROC_UNLOCK(p);
>   }
>   PGRP_UNLOCK(pgrp);
>   }
> - return (nfound ? 0 : ESRCH);
> + return (ret);
>  }
>  
>  #ifndef _SYS_SYSPROTO_H_


pgpfRCVH2nMc2.pgp
Description: PGP signature


svn commit: r242283 - stable/9/sys/kern

2012-10-28 Thread Eitan Adler
Author: eadler
Date: Mon Oct 29 03:52:18 2012
New Revision: 242283
URL: http://svn.freebsd.org/changeset/base/242283

Log:
  MFC r241855,r241859:
Update the kill(2) and killpg(2) man pages to the modern permission
checks. Also indicate killpg(2) is POSIX compliant.
  
Correct the killpg(2) return values:
  
Return EPERM if processes were found but they
were unable to be signaled.
  
Return the first error from p_cansignal if no signal was successful.
  
  Discussed with:   jilles
  Approved by:  cperciva (implicit)

Modified:
  stable/9/sys/kern/kern_sig.c
Directory Properties:
  stable/9/sys/   (props changed)

Modified: stable/9/sys/kern/kern_sig.c
==
--- stable/9/sys/kern/kern_sig.cMon Oct 29 03:52:18 2012
(r242282)
+++ stable/9/sys/kern/kern_sig.cMon Oct 29 03:52:18 2012
(r242283)
@@ -1599,8 +1599,10 @@ killpg1(struct thread *td, int sig, int 
 {
struct proc *p;
struct pgrp *pgrp;
-   int nfound = 0;
+   int err;
+   int ret;
 
+   ret = ESRCH;
if (all) {
/*
 * broadcast
@@ -1613,11 +1615,14 @@ killpg1(struct thread *td, int sig, int 
PROC_UNLOCK(p);
continue;
}
-   if (p_cansignal(td, p, sig) == 0) {
-   nfound++;
+   err = p_cansignal(td, p, sig);
+   if (err == 0) {
if (sig)
pksignal(p, sig, ksi);
+   ret = err;
}
+   else if (ret == ESRCH)
+   ret = err;
PROC_UNLOCK(p);
}
sx_sunlock(&allproc_lock);
@@ -1644,16 +1649,19 @@ killpg1(struct thread *td, int sig, int 
PROC_UNLOCK(p);
continue;
}
-   if (p_cansignal(td, p, sig) == 0) {
-   nfound++;
+   err = p_cansignal(td, p, sig);
+   if (err == 0) {
if (sig)
pksignal(p, sig, ksi);
+   ret = err;
}
+   else if (ret == ESRCH)
+   ret = err;
PROC_UNLOCK(p);
}
PGRP_UNLOCK(pgrp);
}
-   return (nfound ? 0 : ESRCH);
+   return (ret);
 }
 
 #ifndef _SYS_SYSPROTO_H_
___
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"