bug-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

loss of some 'cvs log' output: remote cvs, stderr+stdout, some OS


From: Mike McKay Jr.
Subject: loss of some 'cvs log' output: remote cvs, stderr+stdout, some OS
Date: Thu, 13 May 2004 19:40:05 -0600
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624 Netscape/7.1

Hey,

I am losing some cvs log output when I combine the following things:

  - CVS Versions tried: 1.10, 1.10.8, 1.11.1p1, 1.11.2, 1.12.6
  - Remote CVS using ssh (:ext: method).
    (no problem if using local CVS)
  - Grab standard error and standard out of the 'cvs log' command
    and send that output to another program - see examples below.
    (no problem if I do not grab standard error from the 'cvs log'
     command)
  - OS being Linux(2.4.20-20.9 Red Had release 9) or IRIX64 (6.5).
    (no problem on OSF1 - didn't try other OS's)

I do not know if this is a problem with cvs, my OS, ssh, or what...I am
hoping that you all might have suggestions on what I might do.  Perhaps
you have heard of someone with the same problem and know what they did.

This all came about when I wrote a perl script to massage the stderr/stdout
output from a 'cvs log' command.  Once I used remote cvs with my linux machine,
I noticed the problem.

Here are the steps I am able to do to recreate the problem:

  - Create an empty directory where repo and tests will go and cd there.
    % setenv CHECK_CVS_DIR /tmp/testdir
    % mkdir $CHECK_CVS_DIR
    % cd $CHECK_CVS_DIR
  - Create new repository.
    % cvs -d $CHECK_CVS_DIR/Repo init
  - Create file that simulates a long log message.
    The longer the log message - the more likely the error will happen.
    This is the key - it seems the errors happen when transferring long
    log messages.  Also, the lines of the log message have to be long.
    It might help to have spaces.  It's a mystery to me...
    % mkdir foo && cd foo
% perl -e 'for( $i=0;$i<10000;$i++ ){print "a ";if($i%100==0){print "\n"}};' > ../commit_log_msg
  - Import new module with one file
    % touch bar
    % cvs -d $CHECK_CVS_DIR/Repo import -m initial foo vt rt
  - Remove and checkout foo using Remote CVS
    % cd ..
    % rm -rf foo
    % cvs -d :ext:${HOST}:${CHECK_CVS_DIR}/Repo co foo
    % cd foo
  - Make change to foo and create several long log message versions
    % echo hello >> ./bar && cvs commit -F ../commit_log_msg
    % echo hello >> ./bar && cvs commit -F ../commit_log_msg
    % echo hello >> ./bar && cvs commit -F ../commit_log_msg
    % echo hello >> ./bar && cvs commit -F ../commit_log_msg
  - Test output from several trials.
    seems to occur when trying to grab stderr (which, by the way, there
    is no standard error anyway).
    o This works - no intermediate program.
      % (cvs log bar >   log && wc log) && \
        (cvs log bar > & log && wc log)
    o This sometimes fails (I get about 1/2 failure rate).
      % (cvs log bar |   wc) && \
        (cvs log bar | & wc)
    o This sometimes fails (I get about 1/2 failure rate).
      % (perl -e 'print `cvs log bar     `' | wc) && \
        (perl -e 'print `cvs log bar 2>&1`' | wc)


--
--Mike

---------------------
Mike McKay
address@hidden
505-665-2714
---------------------






reply via email to

[Prev in Thread] Current Thread [Next in Thread]