dev-vcs/cvs: Drop dead package

This commit is contained in:
David Michael 2019-04-02 15:37:21 +00:00
parent d2f311c750
commit adaf89caa2
25 changed files with 0 additions and 988 deletions

View File

@ -1,4 +0,0 @@
DIST cederqvist-1.12.12.html.tar.bz2 137581 SHA256 6bdd66581ec363e05313a14db27cd3c201b547cdfc9ea2f8edde74e78301f0f6 SHA512 c4f6bdc294b719c1c9f6e8b7d1d4faa9e2aafccd37924e9d4772f8d802da3e7f5ae1778b295989db256b23bb1d0914023db7237adaf07833caaee499ae6b6fa3 WHIRLPOOL 41dd1e0d944a02eeca10539b87b5cfcadbf4fd5923c872aa86e5673bb6a98f774d5378e8b4f1c2e6c6a62e6dc6a4d02c69b5e51ad03da899903070effd62adc9
DIST cederqvist-1.12.12.pdf 1252423 SHA256 211c5792d24bfd5694f23bc217a161d880bfb2447c41016fab6f657168b041ce SHA512 aa90b76664ca103cf41831a5595d5e99df9fd87633aa5a500569f43854ca6e409a26b655f02ed59cde1c37ce88c40e06f3b3376ad71fdc9487032c3f0898706a WHIRLPOOL 88d015117c05716df6d0cdc763f16dc488f0641624475e9bd33478485dd32e36a7ee5c49a1789ebdd173e665ae5963e75975342d7308e8e453adb65dd31ec6c5
DIST cederqvist-1.12.12.ps 1262208 SHA256 0e14189614e2c5ead49bfe0ecd187239f8adc3e66371b49d52163be821e44cab SHA512 9a061ef90c664fbb4f882644f72c4f80ffbe0233b6b364511b1c7f18f0a53383980a6ddda326b6df1f2fe1899aed3225de89b55a65a1d9101ba81d1c10c067e2 WHIRLPOOL fb1616ca734e51a626713e7e78786ecbff18378966c2c131f6992df248096d38e850123449d3a5a6aa111ee209f90ef48848da7366b21cb6befeccf07ce54ab6
DIST cvs-1.12.12.tar.bz2 3197171 SHA256 9fb9176d268b9019768fc57dedc2920c28fbeda5ba224c2348550d4f25043edc SHA512 31c679b77b887e02d9c8c381b0dfb42f1207ef4ca806cd92843638eb2126ed032e99bda70a3e20ea2a029670ff39c40088a43435632e381739e6c2f978e6f4bb WHIRLPOOL 74257976cdb957e86fb9fb7e54fc8c0b7210f72136ce05327203d935195e7a3bdda0c1d616dc04cb1d6495cb038ca7275e88488eddb5d936c1cfceb94583278c

View File

@ -1,100 +0,0 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit pam toolchain-funcs
DESCRIPTION="Concurrent Versions System - source code revision control tools"
HOMEPAGE="http://cvs.nongnu.org/"
SRC_URI="mirror://gnu/non-gnu/cvs/source/feature/${PV}/${P}.tar.bz2
doc? ( mirror://gnu/non-gnu/cvs/source/feature/${PV}/cederqvist-${PV}.html.tar.bz2
mirror://gnu/non-gnu/cvs/source/feature/${PV}/cederqvist-${PV}.pdf
mirror://gnu/non-gnu/cvs/source/feature/${PV}/cederqvist-${PV}.ps )"
LICENSE="GPL-2 LGPL-2"
SLOT="0"
KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
IUSE="crypt doc kerberos nls pam server"
RESTRICT="test"
DEPEND=">=sys-libs/zlib-1.1.4
kerberos? ( virtual/krb5 )
pam? ( virtual/pam )"
RDEPEND="${DEPEND}"
src_unpack() {
unpack ${P}.tar.bz2
use doc && unpack cederqvist-${PV}.html.tar.bz2
}
PATCHES=(
"${FILESDIR}"/${P}-cvsbug-tmpfix.patch
"${FILESDIR}"/${P}-openat.patch
"${FILESDIR}"/${P}-block-requests.patch
"${FILESDIR}"/${P}-cvs-gnulib-vasnprintf.patch
"${FILESDIR}"/${P}-install-sh.patch
"${FILESDIR}"/${P}-hash-nameclash.patch # for AIX
"${FILESDIR}"/${P}-getdelim.patch # 314791
"${FILESDIR}"/${PN}-1.12.12-rcs2log-coreutils.patch # 144114
"${FILESDIR}"/${P}-mktime-x32.patch # 395641
"${FILESDIR}"/${P}-fix-massive-leak.patch
"${FILESDIR}"/${P}-mktime-configure.patch #220040 #570208
"${FILESDIR}"/${P}-CVE-2012-0804.patch
"${FILESDIR}"/${P}-format-security.patch
"${FILESDIR}"/${P}-musl.patch
)
DOCS=( BUGS ChangeLog{,.zoo} DEVEL-CVS FAQ HACKING MINOR-BUGS NEWS \
PROJECTS README TESTS TODO )
src_prepare() {
default
sed -i "/^AR/s/ar/$(tc-getAR)/" diff/Makefile.in lib/Makefile.in || die
}
src_configure() {
if tc-is-cross-compiler ; then
# Sane defaults when cross-compiling (as these tests want to
# try and execute code).
export cvs_cv_func_printf_ptr="yes"
fi
econf \
--with-external-zlib \
--with-tmpdir=${EPREFIX%/}/tmp \
$(use_enable crypt encryption) \
$(use_with kerberos gssapi) \
$(use_enable nls) \
$(use_enable pam) \
$(use_enable server)
}
src_install() {
# Not installed into emacs site-lisp because it clobbers the normal C
# indentations.
DOCS+=( cvs-format.el )
if use doc; then
DOCS+=( "${DISTDIR}"/cederqvist-${PV}.{pdf,ps} )
HTML_DOCS=( ../cederqvist-${PV}.html/. )
fi
default
use doc && dosym cvs.html /usr/share/doc/${PF}/html/index.html
if use server; then
newdoc "${FILESDIR}"/cvs-1.12.12-cvs-custom.c cvs-custom.c
insinto /etc/xinetd.d
newins "${FILESDIR}"/cvspserver.xinetd.d cvspserver
newenvd "${FILESDIR}"/01-cvs-env.d 01cvs
fi
newpamd "${FILESDIR}"/cvs.pam-include-1.12.12 cvs
}
pkg_postinst() {
use server || elog "If you want any CVS server functionality, you MUST emerge with USE=server!"
}

View File

@ -1,96 +0,0 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit pam toolchain-funcs
DESCRIPTION="Concurrent Versions System - source code revision control tools"
HOMEPAGE="http://cvs.nongnu.org/"
SRC_URI="mirror://gnu/non-gnu/cvs/source/feature/${PV}/${P}.tar.bz2
doc? ( mirror://gnu/non-gnu/cvs/source/feature/${PV}/cederqvist-${PV}.html.tar.bz2
mirror://gnu/non-gnu/cvs/source/feature/${PV}/cederqvist-${PV}.pdf
mirror://gnu/non-gnu/cvs/source/feature/${PV}/cederqvist-${PV}.ps )"
LICENSE="GPL-2 LGPL-2"
SLOT="0"
KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
IUSE="crypt doc kerberos nls pam server"
RESTRICT="test"
DEPEND=">=sys-libs/zlib-1.1.4
kerberos? ( virtual/krb5 )
pam? ( virtual/pam )"
RDEPEND="${DEPEND}"
src_unpack() {
unpack ${P}.tar.bz2
use doc && unpack cederqvist-${PV}.html.tar.bz2
}
PATCHES=(
"${FILESDIR}"/${P}-cvsbug-tmpfix.patch
"${FILESDIR}"/${P}-openat.patch
"${FILESDIR}"/${P}-block-requests.patch
"${FILESDIR}"/${P}-cvs-gnulib-vasnprintf.patch
"${FILESDIR}"/${P}-install-sh.patch
"${FILESDIR}"/${P}-hash-nameclash.patch # for AIX
"${FILESDIR}"/${P}-getdelim.patch # 314791
"${FILESDIR}"/${PN}-1.12.12-rcs2log-coreutils.patch # 144114
"${FILESDIR}"/${P}-mktime-x32.patch # 395641
"${FILESDIR}"/${P}-fix-massive-leak.patch
"${FILESDIR}"/${P}-mktime-configure.patch #220040 #570208
"${FILESDIR}"/${P}-CVE-2012-0804.patch
"${FILESDIR}"/${P}-format-security.patch
"${FILESDIR}"/${P}-musl.patch
"${FILESDIR}"/${P}-CVE-2017-12836-commandinjection.patch
)
DOCS=( BUGS ChangeLog{,.zoo} DEVEL-CVS FAQ HACKING MINOR-BUGS NEWS \
PROJECTS README TESTS TODO )
src_prepare() {
default
sed -i "/^AR/s:ar:$(tc-getAR):" diff/Makefile.in lib/Makefile.in || die
}
src_configure() {
if tc-is-cross-compiler ; then
# Sane defaults when cross-compiling (as these tests want to
# try and execute code).
export cvs_cv_func_printf_ptr="yes"
fi
econf \
--with-external-zlib \
--with-tmpdir=${EPREFIX%/}/tmp \
$(use_enable crypt encryption) \
$(use_with kerberos gssapi) \
$(use_enable nls) \
$(use_enable pam) \
$(use_enable server)
}
src_install() {
# Not installed into emacs site-lisp because it clobbers the normal C
# indentations.
DOCS+=( cvs-format.el )
if use doc; then
DOCS+=( "${DISTDIR}"/cederqvist-${PV}.{pdf,ps} )
HTML_DOCS=( ../cederqvist-${PV}.html/. )
fi
default
use doc && dosym cvs.html /usr/share/doc/${PF}/html/index.html
if use server; then
newdoc "${FILESDIR}"/cvs-1.12.12-cvs-custom.c cvs-custom.c
insinto /etc/xinetd.d
newins "${FILESDIR}"/cvspserver.xinetd.d cvspserver
newenvd "${FILESDIR}"/01-cvs-env.d 01cvs
fi
newpamd "${FILESDIR}"/cvs.pam-include-1.12.12 cvs
}

View File

@ -1 +0,0 @@
CVS_RSH="ssh"

View File

@ -1,30 +0,0 @@
[CVE-2012-0804] Fix proxy response parser
If proxy sends overlong HTTP vesion string, the string will be copied
to unallocatd space (write_buf) causing heap overflow.
This patch fixes it by ignoring the HTTP version string and checking
the response line has been parsed correctly.
See <https://bugzilla.redhat.com/show_bug.cgi?id=773699> for more
details.
Index: src/client.c
===================================================================
RCS file: /sources/cvs/ccvs/src/client.c,v
retrieving revision 1.483
diff -u -r1.483 client.c
--- a/src/client.c 18 Nov 2008 22:59:02 -0000 1.483
+++ b/src/client.c 26 Jan 2012 16:32:25 -0000
@@ -4339,9 +4339,9 @@
* code.
*/
read_line_via (from_server, to_server, &read_buf);
- sscanf (read_buf, "%s %d", write_buf, &codenum);
+ count = sscanf (read_buf, "%*s %d", &codenum);
- if ((codenum / 100) != 2)
+ if (count != 1 || (codenum / 100) != 2)
error (1, 0, "proxy server %s:%d does not support http tunnelling",
root->proxy_hostname, proxy_port_number);
free (read_buf);

View File

@ -1,22 +0,0 @@
diff -Naurp a/src/rsh-client.c b/src/rsh-client.c
--- a/src/rsh-client.c 2005-03-15 18:45:10.000000000 +0100
+++ b/src/rsh-client.c 2017-08-26 17:43:23.228060155 +0200
@@ -97,6 +97,9 @@ start_rsh_server (cvsroot_t *root, struc
rsh_argv[i++] = root->username;
}
+ /* Only non-option arguments from here. (CVE-2017-12836) */
+ rsh_argv[i++] = "--";
+
rsh_argv[i++] = root->hostname;
rsh_argv[i++] = cvs_server;
rsh_argv[i++] = "server";
@@ -171,6 +174,8 @@ start_rsh_server (cvsroot_t *root, struc
*p++ = root->username;
}
+ *p++ = "--";
+
*p++ = root->hostname;
*p++ = command;
*p++ = NULL;

View File

@ -1,140 +0,0 @@
Author: Robin H. Johnson <robbat2@gentoo.org>
Date: 2006-08-09
This patch allows a CVS server to deny usage of specific commands, based on
input in the environment.
Just set the CVS_BLOCK_REQUESTS env var with all of the commands you want,
seperated by spaces. Eg:
CVS_BLOCK_REQUESTS="Gzip-stream gzip-file-contents"
would block ALL usage of compression.
Please see the array 'struct request requests[]' in src/server.c for a full
list of commands.
Please note that if you block any commands marked as RQ_ESSENTIAL, CVS clients
may fail! (This includes 'ci'!).
See the companion cvs-custom.c for a wrapper that can enforce the environment variable for pserver setups.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
diff -Nuar --exclude '*~' -U 10 cvs-1.12.12.orig/src/server.c cvs-1.12.12/src/server.c
--- cvs-1.12.12.orig/src/server.c 2005-04-14 14:13:29.000000000 +0000
+++ cvs-1.12.12/src/server.c 2006-08-09 01:40:44.000000000 +0000
@@ -5836,43 +5836,90 @@
#undef REQ_LINE
};
#endif /* SERVER_SUPPORT or CLIENT_SUPPORT */
#ifdef SERVER_SUPPORT
/*
* This server request is not ignored by the secondary.
*/
+
+/* Hack by Robin H. Johnson <robbat2@gentoo.org>.
+ * Allow the server ENV to specify what request types are to be ignored.
+ */
+
+static char blocked_requests[BUFSIZ] = " ";
+
+static void build_blocked_requests() {
+ char *tmp = getenv("CVS_BLOCK_REQUESTS");
+
+ if (tmp != NULL && strlen(tmp) > 0) {
+ // move to our custom buffer
+ strncat(blocked_requests, tmp, sizeof(blocked_requests)-strlen(blocked_requests));
+ //add a space on the end as well for searching
+ strncat(blocked_requests, " ", sizeof(blocked_requests)-strlen(blocked_requests));
+ }
+
+ // now blocked_requests contains the list of every request that we do not
+ // want to serve
+}
+
+// returns 0 if we should serve this request
+// use as if(checker(FOO)) continue;
+static int serve_valid_requests_checker(char *reqname) {
+ char needle[BUFSIZ] = " ";
+ char *tmp;
+
+ if(!blocked_requests || strlen(blocked_requests) < 2)
+ return 0;
+
+ // we want to look for ' 'reqname' '
+ snprintf(needle, sizeof(needle), " %s ", reqname);
+
+ // now do the search
+ tmp = strstr(blocked_requests, needle);
+
+ if (tmp != NULL)
+ return 1;
+
+ return 0;
+
+}
+
static void
serve_valid_requests (char *arg)
{
struct request *rq;
/* Since this is processed in the first pass, don't reprocess it in the
* second.
*
* We still print errors since new errors could have been generated in the
* second pass.
*/
if (print_pending_error ()
#ifdef PROXY_SUPPORT
|| reprocessing
#endif /* PROXY_SUPPORT */
)
return;
+
+ build_blocked_requests();
buf_output0 (buf_to_net, "Valid-requests");
for (rq = requests; rq->name != NULL; rq++)
{
if (rq->func != NULL)
{
+ if(serve_valid_requests_checker(rq->name))
+ continue;
buf_append_char (buf_to_net, ' ');
buf_output0 (buf_to_net, rq->name);
}
}
buf_output0 (buf_to_net, "\nok\n");
/* The client is waiting for the list of valid requests, so we
must send the output now. */
buf_flush (buf_to_net, 1);
}
@@ -6353,20 +6400,24 @@
cmd += len;
else if (cmd[len] == ' ')
cmd += len + 1;
else
/*
* The first len characters match, but it's a different
* command. e.g. the command is "cooperate" but we matched
* "co".
*/
continue;
+ // Ignore commands that we are supposed to ignore.
+ if(serve_valid_requests_checker(rq->name))
+ continue;
+
if (!(rq->flags & RQ_ROOTLESS)
&& current_parsed_root == NULL)
{
/* For commands which change the way in which data
is sent and received, for example Gzip-stream,
this does the wrong thing. Since the client
assumes that everything is being compressed,
unconditionally, there is no way to give this
error to the client without turning on

View File

@ -1,58 +0,0 @@
/*
Author: Robin H. Johnson <robbat2@gentoo.org>
Date: 2006-08-09
This patch allows a CVS server to deny usage of specific commands, based on
input in the environment.
Just set the CVS_BLOCK_REQUESTS env var with all of the commands you want,
seperated by spaces. Eg:
CVS_BLOCK_REQUESTS="Gzip-stream gzip-file-contents"
would block ALL usage of compression.
Please see the array 'struct request requests[]' in src/server.c for a full
list of commands.
Please note that if you block any commands marked as RQ_ESSENTIAL, CVS clients
may fail! (This includes 'ci'!).
See the companion cvs-custom.c for a wrapper that can enforce the environment variable for pserver setups.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
*/
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <malloc.h>
#define REAL_CVS "/bin/cvs"
#define CVS_TMPDIR "/tmp"
#define CMDS_BLOCKED " Gzip-stream gzip-file-contents Kerberos-encrypt Gssapi-encrypt Gssapi-authenticate add remove admin import init history watch-on watch-off watch-add watch-remove watchers editors edit version tag rtag "
int main(int argc, char* argv[]) {
char** newargv;
int newargc, offset;
int i;
// 0 for argv[0] we must copy
offset = 0+0;
// +1 for trailing NULL
newargc = argc+offset+1;
newargv = (char**) malloc(newargc*sizeof(char*));
newargv[0] = "cvs";
//newargv[1] = "-T";
//newargv[2] = CVS_TMPDIR;
//newargv[3] = "-R";
for(i=1;i<argc;i++) {
newargv[i+offset] = argv[i];
}
newargv[newargc-1] = NULL;
setenv("CVS_BLOCK_REQUESTS",CMDS_BLOCKED ,1);
//for(i =0;i<newargc;i++) {
// printf("[%d]='%s'\n",i,newargv[i] != NULL ? newargv[i] : "NULL");
//}
execv(REAL_CVS,newargv);
free(newargv);
return 0;
}

View File

@ -1,34 +0,0 @@
http://bugs.gentoo.org/213833
commit 913c09becd9df89dbd9b9f386e7f35c240d5efe8
Author: Bruno Haible <bruno@clisp.org>
Date: Fri Oct 19 01:50:42 2007 +0200
Don't use %n on glibc >= 2.3 systems.
diff --git a/lib/vasnprintf.c b/lib/vasnprintf.c
index f563823..5d818aa 100644
--- a/lib/vasnprintf.c
+++ b/lib/vasnprintf.c
@@ -3385,9 +3385,21 @@ VASNPRINTF (DCHAR_T *resultbuf, size_t *lengthp,
#endif
*p = dp->conversion;
#if USE_SNPRINTF
+# if !(__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 3))
p[1] = '%';
p[2] = 'n';
p[3] = '\0';
+# else
+ /* On glibc2 systems from glibc >= 2.3 - probably also older
+ ones - we know that snprintf's returns value conforms to
+ ISO C 99: the gl_SNPRINTF_DIRECTIVE_N test passes.
+ Therefore we can avoid using %n in this situation.
+ On glibc2 systems from 2004-10-18 or newer, the use of %n
+ in format strings in writable memory may crash the program
+ (if compiled with _FORTIFY_SOURCE=2), so we should avoid it
+ in this situation. */
+ p[1] = '\0';
+# endif
#else
p[1] = '\0';
#endif

View File

@ -1,22 +0,0 @@
Index: cvs-1.12.12/src/cvsbug.in
===================================================================
--- cvs-1.12.12.orig/src/cvsbug.in
+++ cvs-1.12.12/src/cvsbug.in
@@ -109,14 +109,14 @@ elif [ -f /bin/domainname ]; then
/usr/bin/ypcat passwd 2>/dev/null | cat - /etc/passwd | grep "^$LOGNAME:" |
cut -f5 -d':' | sed -e 's/,.*//' > $TEMP
ORIGINATOR="`cat $TEMP`"
- rm -f $TEMP
+ > $TEMP
fi
fi
if [ "$ORIGINATOR" = "" ]; then
grep "^$LOGNAME:" /etc/passwd | cut -f5 -d':' | sed -e 's/,.*//' > $TEMP
ORIGINATOR="`cat $TEMP`"
- rm -f $TEMP
+ > $TEMP
fi
if [ -n "$ORGANIZATION" ]; then

View File

@ -1,52 +0,0 @@
buf_free_data must free data independently
of send or reseived bytes over network.
Moreover, when buffer is usually freed
buffer _is_ empty, but has one clean mapped page.
I've observed massive 'cvs server' leaks
when importing large gentoo-x86 repo with 'cvsps'.
Leak ate all my 32GBs of RAM and killed process.
(Leaked around 3 pages per client request).
valgrind found the leak easily:
$ valgrind \
cvsps \
--root :local:$HOME/portage/gentoo-x86.rsync \
--fast-export \
gentoo-x86/dev-vcs/git-annex 2>l |
git fast-import
==13504== 1,248 bytes in 52 blocks are still reachable in loss record 41 of 47
==13504== at 0x4C2C19B: malloc (vg_replace_malloc.c:270)
==13504== by 0x48A556: xnmalloc_inline (xmalloc.c:40)
==13504== by 0x48A5B5: xmalloc (xmalloc.c:56)
==13504== by 0x4855F5: new_memnode (pagealign_alloc.c:91)
==13504== by 0x48571B: pagealign_alloc (pagealign_alloc.c:151)
==13504== by 0x485739: pagealign_xalloc (pagealign_alloc.c:182)
==13504== by 0x408DD7: get_buffer_data (buffer.c:98)
==13504== by 0x409C0C: buf_input_data (buffer.c:738)
==13504== by 0x45BB63: do_cvs_command (server.c:3847)
==13504== by 0x45D39E: serve_co (server.c:4809)
==13504== by 0x45F845: server (server.c:6438)
==13504== by 0x438784: main (main.c:1066)
And now it takes constant space (less, than 18MB)
for 'cvs server' process to convert all gentoo-x86
by serving more, than 5 000 000 client requests.
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
diff --git a/src/buffer.c b/src/buffer.c
index 3f12513..9a7a559 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -526,7 +526,7 @@ buf_copy_data (struct buffer *buf, struct buffer_data *data,
void
buf_free_data (struct buffer *buffer)
{
- if (buf_empty_p (buffer)) return;
+ if (! buffer->data) return;
buf_free_datas (buffer->data, buffer->last);
buffer->data = buffer->last = NULL;
}

View File

@ -1,22 +0,0 @@
--- a/diff/diff3.c
+++ b/diff/diff3.c
@@ -1503,7 +1503,7 @@
line = 0;
do
{
- printf_output (line_prefix);
+ printf_output ("%s", line_prefix);
cp = D_RELNUM (ptr, realfile, line);
length = D_RELLEN (ptr, realfile, line);
write_output (cp, length);
--- a/src/main.c
+++ b/src/main.c
@@ -1375,7 +1375,7 @@
{
(void) fprintf (stderr, *cpp++, program_name, cvs_cmd_name);
for (; *cpp; cpp++)
- (void) fprintf (stderr, *cpp);
+ (void) fprintf (stderr, "%s", *cpp);
exit (EXIT_FAILURE);
}

View File

@ -1,21 +0,0 @@
The function getdelim() behaves slightly different on FreeBSD,
only appending to the *line buffer if line_size is 0.
See:
https://savannah.nongnu.org/bugs/?29466
http://bugs.gentoo.org/314791
Already comitted upstream:
http://cvs.savannah.gnu.org/viewvc/ccvs/src/myndbm.c?root=cvs&r1=1.38&r2=1.39
--- a/src/myndbm.c.orig
+++ b/src/myndbm.c
@@ -213,7 +213,7 @@
mydbm_load_file (FILE *fp, List *list, char *filename)
{
char *line = NULL;
- size_t line_size;
+ size_t line_size = 0;
char *value;
size_t value_allocated;
char *cp, *vp;

View File

@ -1,42 +0,0 @@
http://cvs.savannah.gnu.org/viewvc/cvs/ccvs/src/hash.h?r1=1.14.6.2&r2=1.14.6.3&pathrev=cvs1-11-x-branch
fixed in cvs-1.11.23, cvs-HEAD after cvs-1.12.13a
--- a/src/hash.h.orig 2005-02-01 22:56:48 +0100
+++ b/src/hash.h 2010-03-10 19:00:11 +0100
@@ -27,26 +27,26 @@
};
typedef enum ntype Ntype;
-struct node
+struct hashnode
{
Ntype type;
- struct node *next;
- struct node *prev;
- struct node *hashnext;
- struct node *hashprev;
+ struct hashnode *next;
+ struct hashnode *prev;
+ struct hashnode *hashnext;
+ struct hashnode *hashprev;
char *key;
void *data;
- void (*delproc) (struct node *);
+ void (*delproc) (struct hashnode *);
};
-typedef struct node Node;
+typedef struct hashnode Node;
-struct list
+struct hashlist
{
Node *list;
Node *hasharray[HASHSIZE];
- struct list *next;
+ struct hashlist *next;
};
-typedef struct list List;
+typedef struct hashlist List;
List *getlist (void);
Node *findnode (List * list, const char *key);

View File

@ -1,12 +0,0 @@
diff -ur a/build-aux/install-sh b/build-aux/install-sh
--- a/build-aux/install-sh 2006-03-25 20:04:46 +0000
+++ b/build-aux/install-sh 2007-09-14 10:53:29 +0100
@@ -246,7 +246,7 @@
fi
if test -n "$dir_arg"; then
- $doit $mkdircmd "$dst" \
+ { test -d "$dst" || $doit $mkdircmd -p "$dst"; } \
&& { test -z "$chowncmd" || $doit $chowncmd "$dst"; } \
&& { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } \
&& { test -z "$stripcmd" || $doit $stripcmd "$dst"; } \

View File

@ -1,201 +0,0 @@
https://bugs.gentoo.org/220040
https://bugs.gentoo.org/570208
update mktime check to latest autoconf version which is less buggy
--- a/configure
+++ b/configure
@@ -5299,26 +6059,25 @@
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
/* Test program from Paul Eggert and Tony Leneis. */
-#if TIME_WITH_SYS_TIME
+#ifdef TIME_WITH_SYS_TIME
# include <sys/time.h>
# include <time.h>
#else
-# if HAVE_SYS_TIME_H
+# ifdef HAVE_SYS_TIME_H
# include <sys/time.h>
# else
# include <time.h>
# endif
#endif
-#if HAVE_STDLIB_H
-# include <stdlib.h>
-#endif
+#include <limits.h>
+#include <stdlib.h>
-#if HAVE_UNISTD_H
+#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
-#if !HAVE_ALARM
+#ifndef HAVE_ALARM
# define alarm(X) /* empty */
#endif
@@ -5335,9 +6094,9 @@
};
#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
-/* Fail if mktime fails to convert a date in the spring-forward gap.
+/* Return 0 if mktime fails to convert a date in the spring-forward gap.
Based on a problem report from Andreas Jaeger. */
-static void
+static int
spring_forward_gap ()
{
/* glibc (up to about 1998-10-07) failed this test. */
@@ -5356,29 +6115,27 @@
tm.tm_min = 0;
tm.tm_sec = 0;
tm.tm_isdst = -1;
- if (mktime (&tm) == (time_t)-1)
- exit (1);
+ return mktime (&tm) != (time_t) -1;
}
-static void
+static int
mktime_test1 (now)
time_t now;
{
struct tm *lt;
- if ((lt = localtime (&now)) && mktime (lt) != now)
- exit (1);
+ return ! (lt = localtime (&now)) || mktime (lt) == now;
}
-static void
+static int
mktime_test (now)
time_t now;
{
- mktime_test1 (now);
- mktime_test1 ((time_t) (time_t_max - now));
- mktime_test1 ((time_t) (time_t_min + now));
+ return (mktime_test1 (now)
+ && mktime_test1 ((time_t) (time_t_max - now))
+ && mktime_test1 ((time_t) (time_t_min + now)));
}
-static void
+static int
irix_6_4_bug ()
{
/* Based on code from Ariel Faigon. */
@@ -5391,11 +6148,10 @@
tm.tm_sec = 0;
tm.tm_isdst = -1;
mktime (&tm);
- if (tm.tm_mon != 2 || tm.tm_mday != 31)
- exit (1);
+ return tm.tm_mon == 2 && tm.tm_mday == 31;
}
-static void
+static int
bigtime_test (j)
int j;
{
@@ -5417,8 +6173,39 @@
&& lt->tm_wday == tm.tm_wday
&& ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
== (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
- exit (1);
+ return 0;
}
+ return 1;
+}
+
+static int
+year_2050_test ()
+{
+ /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
+ ignoring leap seconds. */
+ unsigned long int answer = 2527315200UL;
+
+ struct tm tm;
+ time_t t;
+ tm.tm_year = 2050 - 1900;
+ tm.tm_mon = 2 - 1;
+ tm.tm_mday = 1;
+ tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
+ tm.tm_isdst = -1;
+
+ /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
+ instead of "TZ=America/Vancouver" in order to detect the bug even
+ on systems that don't support the Olson extension, or don't have the
+ full zoneinfo tables installed. */
+ putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
+
+ t = mktime (&tm);
+
+ /* Check that the result is either a failure, or close enough
+ to the correct answer that we can assume the discrepancy is
+ due to leap seconds. */
+ return (t == (time_t) -1
+ || (0 < t && answer - 120 <= t && t <= answer + 120));
}
int
@@ -5432,12 +6219,15 @@
isn't worth using anyway. */
alarm (60);
- for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
- continue;
- time_t_max--;
- if ((time_t) -1 < 0)
- for (time_t_min = -1; (time_t) (time_t_min * 2) < 0; time_t_min *= 2)
- continue;
+ for (;;)
+ {
+ t = (time_t_max << 1) + 1;
+ if (t <= time_t_max)
+ break;
+ time_t_max = t;
+ }
+ time_t_min = - ((time_t) ~ (time_t) 0 == (time_t) -1) - time_t_max;
+
delta = time_t_max / 997; /* a suitable prime number */
for (i = 0; i < N_STRINGS; i++)
{
@@ -5445,18 +6235,22 @@
putenv (tz_strings[i]);
for (t = 0; t <= time_t_max - delta; t += delta)
- mktime_test (t);
- mktime_test ((time_t) 1);
- mktime_test ((time_t) (60 * 60));
- mktime_test ((time_t) (60 * 60 * 24));
-
- for (j = 1; 0 < j; j *= 2)
- bigtime_test (j);
- bigtime_test (j - 1);
+ if (! mktime_test (t))
+ return 1;
+ if (! (mktime_test ((time_t) 1)
+ && mktime_test ((time_t) (60 * 60))
+ && mktime_test ((time_t) (60 * 60 * 24))))
+ return 1;
+
+ for (j = 1; ; j <<= 1)
+ if (! bigtime_test (j))
+ return 1;
+ else if (INT_MAX / 2 < j)
+ break;
+ if (! bigtime_test (INT_MAX))
+ return 1;
}
- irix_6_4_bug ();
- spring_forward_gap ();
- exit (0);
+ return ! (irix_6_4_bug () && spring_forward_gap () && year_2050_test ());
}
_ACEOF
rm -f conftest$ac_exeext

View File

@ -1,29 +0,0 @@
back port changes from upstream gnulib to make this work on x32
https://bugs.gentoo.org/395641
--- cvs-1.12.12/lib/mktime.c
+++ cvs-1.12.12/lib/mktime.c
@@ -115,6 +115,13 @@
#define TM_YEAR_BASE 1900
verify (base_year_is_a_multiple_of_100, TM_YEAR_BASE % 100 == 0);
+#if INT_MAX <= LONG_MAX / 2
+typedef long int long_int;
+#else
+typedef long long int long_int;
+#endif
+verify (long_int_is_wide_enough, INT_MAX == INT_MAX * (long_int) 2 / 2);
+
/* Return 1 if YEAR + TM_YEAR_BASE is a leap year. */
static inline int
leapyear (long int year)
@@ -167,8 +174,6 @@
int year0, int yday0, int hour0, int min0, int sec0)
{
verify (C99_integer_division, -1 / 2 == 0);
- verify (long_int_year_and_yday_are_wide_enough,
- INT_MAX <= LONG_MAX / 2 || TIME_T_MAX <= UINT_MAX);
/* Compute intervening leap days correctly even if year is negative.
Take care to avoid integer overflow here. */

View File

@ -1,13 +0,0 @@
http://gcc.gnu.org/ml/gcc/2003-04/msg00518.html
--- a/lib/regex.c
+++ b/lib/regex.c
@@ -8184,7 +8184,7 @@
if (msg_size > errbuf_size)
{
#if defined HAVE_MEMPCPY || defined _LIBC
- *((char *) __mempcpy (errbuf, msg, errbuf_size - 1)) = '\0';
+ *((char *) mempcpy (errbuf, msg, errbuf_size - 1)) = '\0';
#else
memcpy (errbuf, msg, errbuf_size - 1);
errbuf[errbuf_size - 1] = 0;

View File

@ -1,21 +0,0 @@
Index: cvs-1.12.12/lib/openat.c
===================================================================
--- cvs-1.12.12.orig/lib/openat.c
+++ cvs-1.12.12/lib/openat.c
@@ -55,9 +55,13 @@ rpl_openat (int fd, char const *filename
va_list arg;
va_start (arg, flags);
- /* Assume that mode_t is passed compatibly with mode_t's type
- after argument promotion. */
- mode = va_arg (arg, mode_t);
+ /* If mode_t is narrower than int, use the promoted type (int),
+ not mode_t. Use sizeof to guess whether mode_t is nerrower;
+ we don't know of any practical counterexamples. */
+ if (sizeof (mode_t) < sizeof (int))
+ mode = va_arg (arg, int);
+ else
+ mode = va_arg (arg, mode_t);
va_end (arg);
}

View File

@ -1,14 +0,0 @@
X-Gentoo-bug: 144114
diff -Nuar cvs-1.12.12.orig/contrib/rcs2log.sh cvs-1.12.12/contrib/rcs2log.sh
--- cvs-1.12.12.orig/contrib/rcs2log.sh 2003-02-25 21:32:51.000000000 +0000
+++ cvs-1.12.12/contrib/rcs2log.sh 2010-12-06 21:14:33.831532212 +0000
@@ -620,7 +620,7 @@
# Sort the log entries, first by date+time (in reverse order),
# then by author, then by log entry, and finally by file name and revision
# (just in case).
-sort -t"$SOH" +2 -4r +4 +0 |
+sort -t"$SOH" -k 3,4r -k 5 -k 1,2 |
# Finally, reformat the sorted log entries.
$AWK -F"$SOH" '

View File

@ -1,4 +0,0 @@
#%PAM-1.0
auth include system-auth
account include system-auth
session include system-auth

View File

@ -1,14 +0,0 @@
service cvspserver
{
disable = yes
socket_type = stream
wait = no
user = root
log_type = FILE /var/log/cvspserver
protocol = tcp
env = HOME=/var/cvsroot
log_on_failure += USERID
port = 2401
server = /usr/bin/cvs
server_args = -f --allow-root=/var/cvsroot pserver
}

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<!-- maintainer-needed -->
<use>
<flag name="server">Enable server support</flag>
</use>
</pkgmetadata>

View File

@ -1,14 +0,0 @@
DEFINED_PHASES=configure install postinst prepare unpack
DEPEND=>=sys-libs/zlib-1.1.4 kerberos? ( virtual/krb5 ) pam? ( virtual/pam )
DESCRIPTION=Concurrent Versions System - source code revision control tools
EAPI=6
HOMEPAGE=http://cvs.nongnu.org/
IUSE=crypt doc kerberos nls pam server
KEYWORDS=alpha amd64 arm ~arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris
LICENSE=GPL-2 LGPL-2
RDEPEND=>=sys-libs/zlib-1.1.4 kerberos? ( virtual/krb5 ) pam? ( virtual/pam )
RESTRICT=test
SLOT=0
SRC_URI=mirror://gnu/non-gnu/cvs/source/feature/1.12.12/cvs-1.12.12.tar.bz2 doc? ( mirror://gnu/non-gnu/cvs/source/feature/1.12.12/cederqvist-1.12.12.html.tar.bz2 mirror://gnu/non-gnu/cvs/source/feature/1.12.12/cederqvist-1.12.12.pdf mirror://gnu/non-gnu/cvs/source/feature/1.12.12/cederqvist-1.12.12.ps )
_eclasses_=desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 flag-o-matic 55aaa148741116aa54ad0d80e361818e ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e multilib b2f01ad412baf81650c23fcf0975fa33 pam 3e788d86170dfcd5b06824d898315e18 preserve-libs ef207dc62baddfddfd39a164d9797648 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf
_md5_=ffe26d576740390b6d21c2d672958703

View File

@ -1,14 +0,0 @@
DEFINED_PHASES=configure install prepare unpack
DEPEND=>=sys-libs/zlib-1.1.4 kerberos? ( virtual/krb5 ) pam? ( virtual/pam )
DESCRIPTION=Concurrent Versions System - source code revision control tools
EAPI=6
HOMEPAGE=http://cvs.nongnu.org/
IUSE=crypt doc kerberos nls pam server
KEYWORDS=alpha amd64 arm ~arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris
LICENSE=GPL-2 LGPL-2
RDEPEND=>=sys-libs/zlib-1.1.4 kerberos? ( virtual/krb5 ) pam? ( virtual/pam )
RESTRICT=test
SLOT=0
SRC_URI=mirror://gnu/non-gnu/cvs/source/feature/1.12.12/cvs-1.12.12.tar.bz2 doc? ( mirror://gnu/non-gnu/cvs/source/feature/1.12.12/cederqvist-1.12.12.html.tar.bz2 mirror://gnu/non-gnu/cvs/source/feature/1.12.12/cederqvist-1.12.12.pdf mirror://gnu/non-gnu/cvs/source/feature/1.12.12/cederqvist-1.12.12.ps )
_eclasses_=desktop b1d22ac8bdd4679ab79c71aca235009d epatch a1bf4756dba418a7238f3be0cb010c54 estack 43ddf5aaffa7a8d0482df54d25a66a1f eutils 6e6c2737b59a4b982de6fb3ecefd87f8 flag-o-matic 55aaa148741116aa54ad0d80e361818e ltprune 08f9e1d9ee0af8f5d9a7854efbcd8c0e multilib b2f01ad412baf81650c23fcf0975fa33 pam 3e788d86170dfcd5b06824d898315e18 preserve-libs ef207dc62baddfddfd39a164d9797648 toolchain-funcs f164325a2cdb5b3ea39311d483988861 vcs-clean 2a0f74a496fa2b1552c4f3398258b7bf
_md5_=68022da287f504b569d22661fe607407