Re: weird diffs in cvsweb

2008-10-08 Thread Philip Guenther
On Wed, Oct 8, 2008 at 2:40 PM, umaxx <[EMAIL PROTECTED]> wrote:
> Sorry for hijacking this thread,

I didn't know starting new threads was more difficult than hijacking
an existing one.


> but I stumbled today over this error in cvsweb if downloading any file:
...
> http://www.openbsd.org/cgi-bin/cvsweb/~checkout~/ports/devel/geany/Makefile?rev=1.17&content-type=text/plain
>
> Maybe (unlikely) this has something todo with the issues mentioned
> above.

Nope, completely unrelated.  That should be filed as a bug in the
openbsd pr database using 'sendbug'.  Looks like a simple substitution
error or typo in the cvsweb program.


Philip Guenther



Re: weird diffs in cvsweb

2008-10-08 Thread umaxx
Hi,

On Wed, 8 Oct 2008 17:01:03 -0400
"Ted Unangst" <[EMAIL PROTECTED]> wrote:

> On Wed, Oct 8, 2008 at 4:32 PM, Matthias Kilian
> <[EMAIL PROTECTED]> wrote:
> > On Wed, Oct 08, 2008 at 10:08:03PM +0200, Otto Moerbeek wrote:
> >> > > Is CVSWEB broken?
> >> >
> >> > No, that's just the way CVS keywords work: the expansion is done
> >> > at *checkout* and not at commit.  This can be seen using the -ko
> >> > option to "cvs up" or "cvs co" to disable the expansion done at
> >> > checkout time.  Just trust what you see on the revision listing
> >> > and ignore the keywords in the diff output.
> >> >
> >> > (Beware: the -k option is normally 'sticky', so if you use -ko
> >> > you should either combine it with -p to just send the output to
> >> > stdout (in which case the -ko isn't sticky) or do a fresh update
> >> > with -A to 'unstick' it.  Of course, the -A will also clear any
> >> > -r option you had...)
> > [...]
> >> but when I do a
> >>
> >>   cvs diff -r 1.94 -r 1.95 if_tun.c
> >>
> >> on my local mirror i'm seeing the right $OpenBSD$ markers.
> >
> > What's right and what's wrong? Try
> >
> > $ cvs -q di -ko -r1.9{4,5} if_tun.c
> >
> > I guess cvsweb is using -ko for diffs, to show the diffs in the
> > *repository*, not what you would see in a working directory.
> 
> I think it used to show diffs that looked more like the command line
> versions, because I've never noticed they were wrong before, and I've
> certainly looked at them in the past.

Sorry for hijacking this thread, but I stumbled today over this
error in cvsweb if downloading any file:

"Error: Unexpected output from cvs co cvs checkout aborted Absolute
module reference invalid /ports/devel/geany/MakefilepbCheck whether the
directory /cvs/CVSROOT exists and the script has write-access to the
CVSROOT/history file if it exists.brThe script needs to place lock
files in the directory the file is in as well./b"

http://www.openbsd.org/cgi-bin/cvsweb/~checkout~/ports/devel/geany/Makefile?rev=1.17&content-type=text/plain

Maybe (unlikely) this has something todo with the issues mentioned
above.

If this error is already known or wanted, then sorry for the noise.

Regards,

Joerg



Re: weird diffs in cvsweb

2008-10-08 Thread Ted Unangst
On Wed, Oct 8, 2008 at 4:32 PM, Matthias Kilian <[EMAIL PROTECTED]> wrote:
> On Wed, Oct 08, 2008 at 10:08:03PM +0200, Otto Moerbeek wrote:
>> > > Is CVSWEB broken?
>> >
>> > No, that's just the way CVS keywords work: the expansion is done at
>> > *checkout* and not at commit.  This can be seen using the -ko option
>> > to "cvs up" or "cvs co" to disable the expansion done at checkout
>> > time.  Just trust what you see on the revision listing and ignore the
>> > keywords in the diff output.
>> >
>> > (Beware: the -k option is normally 'sticky', so if you use -ko you
>> > should either combine it with -p to just send the output to stdout (in
>> > which case the -ko isn't sticky) or do a fresh update with -A to
>> > 'unstick' it.  Of course, the -A will also clear any -r option you
>> > had...)
> [...]
>> but when I do a
>>
>>   cvs diff -r 1.94 -r 1.95 if_tun.c
>>
>> on my local mirror i'm seeing the right $OpenBSD$ markers.
>
> What's right and what's wrong? Try
>
> $ cvs -q di -ko -r1.9{4,5} if_tun.c
>
> I guess cvsweb is using -ko for diffs, to show the diffs in the
> *repository*, not what you would see in a working directory.

I think it used to show diffs that looked more like the command line
versions, because I've never noticed they were wrong before, and I've
certainly looked at them in the past.



Re: weird diffs in cvsweb

2008-10-08 Thread Matthias Kilian
On Wed, Oct 08, 2008 at 10:08:03PM +0200, Otto Moerbeek wrote:
> > > Is CVSWEB broken?
> > 
> > No, that's just the way CVS keywords work: the expansion is done at
> > *checkout* and not at commit.  This can be seen using the -ko option
> > to "cvs up" or "cvs co" to disable the expansion done at checkout
> > time.  Just trust what you see on the revision listing and ignore the
> > keywords in the diff output.
> > 
> > (Beware: the -k option is normally 'sticky', so if you use -ko you
> > should either combine it with -p to just send the output to stdout (in
> > which case the -ko isn't sticky) or do a fresh update with -A to
> > 'unstick' it.  Of course, the -A will also clear any -r option you
> > had...)
[...]
> but when I do a
> 
>   cvs diff -r 1.94 -r 1.95 if_tun.c 
> 
> on my local mirror i'm seeing the right $OpenBSD$ markers.

What's right and what's wrong? Try

$ cvs -q di -ko -r1.9{4,5} if_tun.c

I guess cvsweb is using -ko for diffs, to show the diffs in the
*repository*, not what you would see in a working directory.

Ciao,
Kili

-- 
kili slowly fills the attic...
-- mbalmer



Re: weird diffs in cvsweb

2008-10-08 Thread Philip Guenther
On Wed, Oct 8, 2008 at 1:08 PM, Otto Moerbeek <[EMAIL PROTECTED]> wrote:
> On Wed, Oct 08, 2008 at 12:44:43PM -0700, Philip Guenther wrote:
>> On Wed, Oct 8, 2008 at 12:27 PM, Peter J. Philipp <[EMAIL PROTECTED]> wrote:
>> > I'm not just seeing this wrong I hope.  Let me explain:
>> >
>> > http://www.openbsd.org/cgi-bin/cvsweb/src/sys/net/if_tun.c
>> >
>> > when looking at the top seeing the change 1.95 done by brad@, but when
>> > selecting to see diffs with 1.94 the change in $OpenBSD$ tag reflects 
>> > damien
>> > and mpf who were the committers one commit before 1.95.  This causes a bit
>> > of confusion on my part, for who committed what, what are brad's changes?
>> >
>> > Is CVSWEB broken?
>>
>> No, that's just the way CVS keywords work: the expansion is done at
>> *checkout* and not at commit.  This can be seen using the -ko option
>> to "cvs up" or "cvs co" to disable the expansion done at checkout
>> time.  Just trust what you see on the revision listing and ignore the
>> keywords in the diff output.
>
> but when I do a
>
>cvs diff -r 1.94 -r 1.95 if_tun.c
>
> on my local mirror i'm seeing the right $OpenBSD$ markers. Compere the
> output below to
>
> http://www.openbsd.org/cgi-bin/cvsweb/src/sys/net/if_tun.c.diff?r1=1.94&r2=1.95
>
> I'd say something's fishy here.

Hmm, good point.  It's like it passes the -ko option to cvs diff.  Or
does cvsweb implement the diff itself internally?  It has to peek
directly at the RCS files to get some of the other stuff it shows, no?


Philip Guenther



Re: weird diffs in cvsweb

2008-10-08 Thread Otto Moerbeek
On Wed, Oct 08, 2008 at 12:44:43PM -0700, Philip Guenther wrote:

> On Wed, Oct 8, 2008 at 12:27 PM, Peter J. Philipp <[EMAIL PROTECTED]> wrote:
> > I'm not just seeing this wrong I hope.  Let me explain:
> >
> > http://www.openbsd.org/cgi-bin/cvsweb/src/sys/net/if_tun.c
> >
> > when looking at the top seeing the change 1.95 done by brad@, but when
> > selecting to see diffs with 1.94 the change in $OpenBSD$ tag reflects damien
> > and mpf who were the committers one commit before 1.95.  This causes a bit
> > of confusion on my part, for who committed what, what are brad's changes?
> >
> > Is CVSWEB broken?
> 
> No, that's just the way CVS keywords work: the expansion is done at
> *checkout* and not at commit.  This can be seen using the -ko option
> to "cvs up" or "cvs co" to disable the expansion done at checkout
> time.  Just trust what you see on the revision listing and ignore the
> keywords in the diff output.
> 
> (Beware: the -k option is normally 'sticky', so if you use -ko you
> should either combine it with -p to just send the output to stdout (in
> which case the -ko isn't sticky) or do a fresh update with -A to
> 'unstick' it.  Of course, the -A will also clear any -r option you
> had...)
> 
> 
> Philip Guenther

but when I do a

cvs diff -r 1.94 -r 1.95 if_tun.c 

on my local mirror i'm seeing the right $OpenBSD$ markers. Compere the
output below to 

http://www.openbsd.org/cgi-bin/cvsweb/src/sys/net/if_tun.c.diff?r1=1.94&r2=1.95

I'd say something's fishy here.

-Otto

Index: if_tun.c
===
RCS file: /cvs/src/sys/net/if_tun.c,v
retrieving revision 1.94
retrieving revision 1.95
diff -u -p -r1.94 -r1.95
--- if_tun.c4 Aug 2008 18:55:08 -   1.94
+++ if_tun.c2 Oct 2008 20:21:14 -   1.95
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_tun.c,v 1.94 2008/08/04 18:55:08 damien Exp $  */
+/* $OpenBSD: if_tun.c,v 1.95 2008/10/02 20:21:14 brad Exp $*/
 /* $NetBSD: if_tun.c,v 1.24 1996/05/07 02:40:48 thorpej Exp $  */
 
 /*
@@ -438,11 +438,7 @@ tun_ioctl(struct ifnet *ifp, u_long cmd,
int  error = 0, s;
 
s = splnet();
-   if (tp->tun_flags & TUN_LAYER2)
-   if ((error = ether_ioctl(ifp, &tp->arpcom, cmd, data)) > 0) {
-   splx(s);
-   return (error);
-   }
+
switch (cmd) {
case SIOCSIFADDR:
tuninit(tp);
@@ -515,8 +511,12 @@ tun_ioctl(struct ifnet *ifp, u_long cmd,
ifp->if_flags & IFF_LINK0 ? TUN_LAYER2 : 0);
break;
default:
-   error = ENOTTY;
+   if (tp->tun_flags & TUN_LAYER2)
+   error = ether_ioctl(ifp, &tp->arpcom, cmd, data);
+   else
+   error = ENOTTY;
}
+
splx(s);
return (error);
 }



Re: weird diffs in cvsweb

2008-10-08 Thread Philip Guenther
On Wed, Oct 8, 2008 at 12:27 PM, Peter J. Philipp <[EMAIL PROTECTED]> wrote:
> I'm not just seeing this wrong I hope.  Let me explain:
>
> http://www.openbsd.org/cgi-bin/cvsweb/src/sys/net/if_tun.c
>
> when looking at the top seeing the change 1.95 done by brad@, but when
> selecting to see diffs with 1.94 the change in $OpenBSD$ tag reflects damien
> and mpf who were the committers one commit before 1.95.  This causes a bit
> of confusion on my part, for who committed what, what are brad's changes?
>
> Is CVSWEB broken?

No, that's just the way CVS keywords work: the expansion is done at
*checkout* and not at commit.  This can be seen using the -ko option
to "cvs up" or "cvs co" to disable the expansion done at checkout
time.  Just trust what you see on the revision listing and ignore the
keywords in the diff output.

(Beware: the -k option is normally 'sticky', so if you use -ko you
should either combine it with -p to just send the output to stdout (in
which case the -ko isn't sticky) or do a fresh update with -A to
'unstick' it.  Of course, the -A will also clear any -r option you
had...)


Philip Guenther



weird diffs in cvsweb

2008-10-08 Thread Peter J. Philipp

I'm not just seeing this wrong I hope.  Let me explain:

http://www.openbsd.org/cgi-bin/cvsweb/src/sys/net/if_tun.c

when looking at the top seeing the change 1.95 done by brad@, but when 
selecting to see diffs with 1.94 the change in $OpenBSD$ tag reflects 
damien and mpf who were the committers one commit before 1.95.  This 
causes a bit of confusion on my part, for who committed what, what are 
brad's changes?


Is CVSWEB broken?


Regards,

-peter