Actions:
|
2008-05-15 11:20 AEST by Arthur Barrett - modules file does not support "-d ." but does not complain either.
CVSNT 1.10.8 did support this syntax but CVSNT 2.5.x does not (it was removed
ages and ages ago). The problem is that the documentation and
default "modules" file do not make this clear and the syntax is silently
accepted but rubbish returned.
At a minimum the server should abort, and at best it could support it
with 'curdir' name on client somehow - see bug5276.
If the modules specifies the directory "someplace" and the client
specifies "woo" on the command line then "woo" is used. Similarly if modules
specifies the directory "someplace" and the client specifies "." then "." is
used (due to the fix for bug 5276).
Sample modules file:
steve -d . devel/steve
bob -d someplace devel/bob
stuff -a steve bob
Reading the options is handled in do_module() of modules.cpp, however the
actual "error" from handling "." is likely to be buried deep in rcs.cpp - even
if it's possible to support it at all.
If you currently specify " -d . devel/steve" it actually checks out the
module "." not the target "." which is quite severe.
It'd be ideal to send the client a notification that this is happening so it
can just "cd .." as in the solution to bug 5276... |
|
2008-05-15 12:28 AEST by Arthur Barrett - Created an attachment (id=1281)
Proposed patch
This patch just recognises the error in CVSROOT\Modules and causes the server
to terminate. The server administrator can set ModuleDotOK=1 in
/etc/cvsnt/PServer or in the windows registry to override the error.
The client now will try and send the "current directory" to the server and if
it has been sent and ModuleDotOK is also set then the server will report this.
Checking in src/checkout.cpp;
/cvs/cvsnt/src/checkout.c,v <-- checkout.cpp
new revision: 1.26.2.69.6.12; previous revision: 1.26.2.69.6.11
done
Checking in src/modules.cpp;
/cvs/cvsnt/src/modules.c,v <-- modules.cpp
new revision: 1.15.2.39.8.4; previous revision: 1.15.2.39.8.3
done
Checking in src/server.cpp;
/cvs/cvsnt/src/server.c,v <-- server.cpp
new revision: 1.106.2.210.6.26; previous revision: 1.106.2.210.6.25
done
|
|
2008-05-20 10:45 AEST by Arthur Barrett - Customer during testing complains that some files now get checked out to "..".
Firstly I've modified the client code to ensure that !!module only causes the
client to cd .. once:
Checking in src/client.cpp;
/cvs/cvsnt/src/client.c,v <-- client.cpp
new revision: 1.84.2.141.6.21; previous revision: 1.84.2.141.6.20
done
Checking in src/cvs.h;
/cvs/cvsnt/src/cvs.h,v <-- cvs.h
new revision: 1.93.2.208.6.6; previous revision: 1.93.2.208.6.5
done
Secondly need to add test cases such as this modules:
welk -d blah devel/steve CHANGELOG
weez -d . devel/steve CHANGELOG
woop -d . devel/steve
wow -d something devel/bob
several -a woop wow
|
|
2008-05-23 14:51 AEST by Arthur Barrett - Still working on combinations of this... The current hiccups are with static
directories...
Checking in src/server.cpp;
/cvs/cvsnt/src/server.c,v <-- server.cpp
new revision: 1.106.2.210.6.41; previous revision: 1.106.2.210.6.40
done
|
|
2008-05-24 12:24 AEST by Arthur Barrett - testing build 3109 - this appears to be fixed. Marking as fixed. |
|
2008-07-17 07:27 AEST by Arthur Barrett - Problem still occurring:
steve -d . devel/steve COPYING
stevie -d . devel/steve
babby -d woop devel/steve COPYING
bob -d someplace devel/bob
beau -d tools devel/bob
twoa -d fred CVSROOT/config CVSROOT/modules
twob -d somewhere devel/bob devel/steve
stuff -a steve bob
bmr -a stevie beau
[abarrett@rhelv4 test]$ mkdir t; cd t
[abarrett@rhelv4 t]$ export CVS_CLIENT_LOG=$HOME/bmr123
[abarrett@rhelv4 t]$ cvs -ttt -d :pserver:rhelv4:/home/source/repository/tmon
co bmr > $HOME/bmr-test.txt 2> $HOME/bmr-test-err.txt
11:05:25: -> start_recursion: Free the data - update_dir
11:05:25: -> start_recursion: Free the data - update_repos
11:05:25: -> start_recursion: (args_to_send_when_finished == NULL)
11:05:25: -> start_recursion: return 0.
11:05:25: -> send_repository(,/home/source/repository/tmon,.)
11:05:25: -> allocate adm_name * 80 is large enough for any of CVSADM_*.
11:05:25: -> * Send the directory name.
11:05:25: -> checkout() at end CURDIR="/home/abarrett/test".
11:05:25: -> checkout() at end should be="/home/abarrett/test".
11:05:25: -> checkout() CHDIR(/home/abarrett/test/t) back from
client_handle_go_up()
11:05:25: -> checkout args[1]="tools" after client_handle_go_up() stuff
11:05:25: -> send_a_repository(,/home/source/repository/tmon,)
11:05:25: -> send_repository(,/home/source/repository/tmon,)
11:05:25: S -> server_main started
11:05:25: S -> run plugintools proc server
11:05:25: S -> run_trigger()
11:05:25: S -> Checking admin file /usr/local/repo/tmon/CVSROOT/admin for user
abarrett
11:05:25: S -> Checking started in admin
file /usr/local/repo/tmon/CVSROOT/admin for user abarrett
|
|
2008-12-03 11:40 AEST by Arthur Barrett - Still working on this, removing keywords 3226, 2.5.03 but still hope to get this completed as a
maintenance patch on CVS Suite 2008. |
|
2012-01-07 07:56 AEST by Arthur Barrett - this is the dotmodule setting |