From: deraadt Date: Wed, 27 Jan 2021 07:18:16 +0000 (+0000) Subject: fix -fno-common issues; ok mortimer X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=2f43a3f5488752f16be4ec77bf146703768436fa;p=openbsd fix -fno-common issues; ok mortimer --- diff --git a/usr.bin/cvs/cvs.c b/usr.bin/cvs/cvs.c index 01f129e9d96..492376b0143 100644 --- a/usr.bin/cvs/cvs.c +++ b/usr.bin/cvs/cvs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cvs.c,v 1.159 2017/06/01 08:08:24 joris Exp $ */ +/* $OpenBSD: cvs.c,v 1.160 2021/01/27 07:18:16 deraadt Exp $ */ /* * Copyright (c) 2006, 2007 Joris Vink * Copyright (c) 2004 Jean-Francois Brousseau @@ -73,6 +73,8 @@ int cvs_getopt(int, char **); __dead void usage(void); static void cvs_read_rcfile(void); +struct cvs_varhead cvs_variables; + struct wklhead temp_files; void sighandler(int); diff --git a/usr.bin/cvs/cvs.h b/usr.bin/cvs/cvs.h index 63e0f1e0c03..7793e177253 100644 --- a/usr.bin/cvs/cvs.h +++ b/usr.bin/cvs/cvs.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cvs.h,v 1.184 2017/06/01 08:08:24 joris Exp $ */ +/* $OpenBSD: cvs.h,v 1.185 2021/01/27 07:18:17 deraadt Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau * All rights reserved. @@ -189,7 +189,7 @@ struct cvs_var { TAILQ_ENTRY(cvs_var) cv_link; }; -TAILQ_HEAD(, cvs_var) cvs_variables; +extern TAILQ_HEAD(cvs_varhead, cvs_var) cvs_variables; #define CVS_ROOT_CONNECTED 0x01 diff --git a/usr.bin/cvs/tag.c b/usr.bin/cvs/tag.c index a118827eb21..21769dea714 100644 --- a/usr.bin/cvs/tag.c +++ b/usr.bin/cvs/tag.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tag.c,v 1.87 2017/06/01 08:08:24 joris Exp $ */ +/* $OpenBSD: tag.c,v 1.88 2021/01/27 07:18:17 deraadt Exp $ */ /* * Copyright (c) 2006 Xavier Santolaria * @@ -34,7 +34,7 @@ void cvs_tag_local(struct cvs_file *); static int tag_del(struct cvs_file *); static int tag_add(struct cvs_file *); -struct file_info_list files_info; +struct file_info_list tag_files_info; static int runflags = 0; static int tag_errors = 0; @@ -199,7 +199,7 @@ cvs_tag(int argc, char **argv) if (cvs_cmdop == CVS_OP_RTAG && chdir(current_cvsroot->cr_dir) == -1) fatal("cvs_tag: %s", strerror(errno)); - TAILQ_INIT(&files_info); + TAILQ_INIT(&tag_files_info); cvs_get_repository_name(".", repo, PATH_MAX); line_list = cvs_trigger_getlines(CVS_PATH_TAGINFO, repo); @@ -216,7 +216,7 @@ cvs_tag(int argc, char **argv) if (line_list != NULL) { if (cvs_trigger_handle(CVS_TRIGGER_TAGINFO, repo, NULL, - line_list, &files_info)) + line_list, &tag_files_info)) fatal("Pre-tag check failed"); cvs_trigger_freelist(line_list); } @@ -229,7 +229,7 @@ cvs_tag(int argc, char **argv) cvs_file_run(1, &arg, &cr); if (line_list != NULL) - cvs_trigger_freeinfo(&files_info); + cvs_trigger_freeinfo(&tag_files_info); return (0); } @@ -309,7 +309,7 @@ cvs_tag_check_files(struct cvs_file *cf) else fi->tag_op = "add"; - TAILQ_INSERT_TAIL(&files_info, fi, flist); + TAILQ_INSERT_TAIL(&tag_files_info, fi, flist); return; bad: