зеркало из https://github.com/mozilla/pjs.git
57 строки
1.8 KiB
Diff
57 строки
1.8 KiB
Diff
|
Index: doc/cvs.texinfo
|
||
|
===================================================================
|
||
|
RCS file: /b/cvsroot/misc/cvs/doc/cvs.texinfo,v
|
||
|
retrieving revision 1.1.1.1
|
||
|
retrieving revision 1.2
|
||
|
diff -u -r1.1.1.1 -r1.2
|
||
|
--- cvs.texinfo 1997/12/19 21:24:55 1.1.1.1
|
||
|
+++ cvs.texinfo 1997/12/22 19:43:15 1.2
|
||
|
@@ -11620,6 +11620,13 @@
|
||
|
@item USER
|
||
|
Username of the user running @sc{cvs} (on the @sc{cvs}
|
||
|
server machine).
|
||
|
+
|
||
|
+@item CVS_USER
|
||
|
+This is set to the username provided by the user when
|
||
|
+the pserver or kserver access methods are used, and to
|
||
|
+the empty string otherwise. (CVS_USER and USER may
|
||
|
+differ when @file{$CVSROOT/CVSROOT/passwd} is used to
|
||
|
+map cvs usernames to system usernames.)
|
||
|
@end table
|
||
|
|
||
|
If you want to pass a value to the administrative files
|
||
|
Index: src/server.c
|
||
|
===================================================================
|
||
|
RCS file: /b/cvsroot/misc/cvs/src/server.c,v
|
||
|
retrieving revision 1.1.1.1
|
||
|
retrieving revision 1.2
|
||
|
diff -u -r1.1.1.1 -r1.2
|
||
|
--- server.c 1997/12/19 21:24:53 1.1.1.1
|
||
|
+++ server.c 1997/12/22 19:43:18 1.2
|
||
|
@@ -4384,10 +4384,10 @@
|
||
|
umask (0);
|
||
|
|
||
|
#if HAVE_PUTENV
|
||
|
- /* Set LOGNAME and USER in the environment, in case they are
|
||
|
- already set to something else. */
|
||
|
+ /* Set LOGNAME, USER and CVS_USER in the environment, in case they
|
||
|
+ are already set to something else. */
|
||
|
{
|
||
|
- char *env;
|
||
|
+ char *env, *cvs_user;
|
||
|
|
||
|
env = xmalloc (sizeof "LOGNAME=" + strlen (username));
|
||
|
(void) sprintf (env, "LOGNAME=%s", username);
|
||
|
@@ -4396,6 +4396,11 @@
|
||
|
env = xmalloc (sizeof "USER=" + strlen (username));
|
||
|
(void) sprintf (env, "USER=%s", username);
|
||
|
(void) putenv (env);
|
||
|
+
|
||
|
+ cvs_user = NULL != CVS_Username ? CVS_Username : "";
|
||
|
+ env = xmalloc (sizeof "CVS_USER=" + strlen (cvs_user));
|
||
|
+ (void) sprintf (env, "CVS_USER=%s", cvs_user);
|
||
|
+ (void) putenv (env);
|
||
|
}
|
||
|
#endif /* HAVE_PUTENV */
|
||
|
}
|