version 1.18, 2005/05/31 08:58:48 |
version 1.19, 2005/06/28 14:34:56 |
|
|
}; |
}; |
|
|
static int flags = 0; |
static int flags = 0; |
static char *rev = NULL; |
static char *date, *rev, *user, *tag; |
static char *user = NULL; |
|
static char *zone = "+0000"; |
static char *zone = "+0000"; |
static char *tag = NULL; |
|
static u_int nbmod = 0; |
static u_int nbmod = 0; |
static u_int rep = 0; |
static u_int rep = 0; |
static char *modules[CVS_HISTORY_MAXMOD]; |
static char *modules[CVS_HISTORY_MAXMOD]; |
|
|
{ |
{ |
int ch; |
int ch; |
|
|
|
date = rev = user = tag = NULL; |
|
|
while ((ch = getopt(argc, argv, cmd->cmd_opts)) != -1) { |
while ((ch = getopt(argc, argv, cmd->cmd_opts)) != -1) { |
switch (ch) { |
switch (ch) { |
case 'a': |
case 'a': |
|
|
if ((flags & CVS_HF_O) && (cvs_sendarg(root, "-o", 0) < 0)) |
if ((flags & CVS_HF_O) && (cvs_sendarg(root, "-o", 0) < 0)) |
return (CVS_EX_PROTO); |
return (CVS_EX_PROTO); |
|
|
if (rev != NULL) { |
if ((date != NULL) && ((cvs_sendarg(root, "-D", 0) < 0) || |
if ((cvs_sendarg(root, "-r", 0) < 0) || |
(cvs_sendarg(root, date, 0) < 0))) |
(cvs_sendarg(root, rev, 0) < 0)) |
return (CVS_EX_PROTO); |
|
|
|
if ((rev != NULL) && ((cvs_sendarg(root, "-r", 0) < 0) || |
|
(cvs_sendarg(root, rev, 0) < 0))) |
return (CVS_EX_PROTO); |
return (CVS_EX_PROTO); |
} |
|
|
|
if (tag != NULL) { |
if ((tag != NULL) && ((cvs_sendarg(root, "-t", 0) < 0) || |
if ((cvs_sendarg(root, "-t", 0) < 0) || |
(cvs_sendarg(root, tag, 0) < 0))) |
(cvs_sendarg(root, tag, 0) < 0)) |
|
return (CVS_EX_PROTO); |
return (CVS_EX_PROTO); |
} |
|
|
|
/* if no user is specified, get login name of command issuer */ |
/* if no user is specified, get login name of command issuer */ |
if (!(flags & CVS_HF_A) && (user == NULL)) { |
if (!(flags & CVS_HF_A) && (user == NULL)) { |