summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXavier Santolaria <xsa@cvs.openbsd.org>2005-07-25 12:05:44 +0000
committerXavier Santolaria <xsa@cvs.openbsd.org>2005-07-25 12:05:44 +0000
commitc881ebf8d29951dd1a85fc7c1e3c1236021b4697 (patch)
treec924ce43a79f7fa2f3c768c41b8e174c2e6f94db
parent5acdc59b80474dc1722a5c5439df2d68aabe7a52 (diff)
KNF;
-rw-r--r--usr.bin/cvs/admin.c10
-rw-r--r--usr.bin/cvs/annotate.c10
-rw-r--r--usr.bin/cvs/buf.c22
-rw-r--r--usr.bin/cvs/checkout.c10
-rw-r--r--usr.bin/cvs/cmd.c6
-rw-r--r--usr.bin/cvs/commit.c12
-rw-r--r--usr.bin/cvs/cvs.c10
-rw-r--r--usr.bin/cvs/diff.c95
-rw-r--r--usr.bin/cvs/edit.c8
-rw-r--r--usr.bin/cvs/entries.c12
-rw-r--r--usr.bin/cvs/file.c28
-rw-r--r--usr.bin/cvs/getlog.c16
-rw-r--r--usr.bin/cvs/hist.c8
-rw-r--r--usr.bin/cvs/history.c32
-rw-r--r--usr.bin/cvs/import.c18
-rw-r--r--usr.bin/cvs/init.c16
-rw-r--r--usr.bin/cvs/logmsg.c6
-rw-r--r--usr.bin/cvs/proto.c8
-rw-r--r--usr.bin/cvs/rcs.c168
-rw-r--r--usr.bin/cvs/rcsnum.c4
-rw-r--r--usr.bin/cvs/repo.c4
-rw-r--r--usr.bin/cvs/resp.c4
-rw-r--r--usr.bin/cvs/root.c4
-rw-r--r--usr.bin/cvs/strtab.c28
-rw-r--r--usr.bin/cvs/util.c6
-rw-r--r--usr.bin/cvs/zlib.c12
26 files changed, 279 insertions, 278 deletions
diff --git a/usr.bin/cvs/admin.c b/usr.bin/cvs/admin.c
index f08b2962e79..842f8d15464 100644
--- a/usr.bin/cvs/admin.c
+++ b/usr.bin/cvs/admin.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: admin.c,v 1.21 2005/07/18 07:22:23 xsa Exp $ */
+/* $OpenBSD: admin.c,v 1.22 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* Copyright (c) 2005 Joris Vink <joris@openbsd.org>
@@ -48,10 +48,10 @@
#define FLAG_INTERACTIVE 0x04
#define FLAG_QUIET 0x08
-static int cvs_admin_init (struct cvs_cmd *, int, char **, int *);
-static int cvs_admin_pre_exec (struct cvsroot *);
-static int cvs_admin_remote (CVSFILE *, void *);
-static int cvs_admin_local (CVSFILE *, void *);
+static int cvs_admin_init(struct cvs_cmd *, int, char **, int *);
+static int cvs_admin_pre_exec(struct cvsroot *);
+static int cvs_admin_remote(CVSFILE *, void *);
+static int cvs_admin_local(CVSFILE *, void *);
struct cvs_cmd cvs_cmd_admin = {
CVS_OP_ADMIN, CVS_REQ_ADMIN, "admin",
diff --git a/usr.bin/cvs/annotate.c b/usr.bin/cvs/annotate.c
index 553164e4b4b..adb9bd86ecc 100644
--- a/usr.bin/cvs/annotate.c
+++ b/usr.bin/cvs/annotate.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: annotate.c,v 1.22 2005/07/21 11:42:24 xsa Exp $ */
+/* $OpenBSD: annotate.c,v 1.23 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -38,10 +38,10 @@
#include "proto.h"
-static int cvs_annotate_init (struct cvs_cmd *, int, char **, int *);
-static int cvs_annotate_remote (CVSFILE *, void *);
-static int cvs_annotate_local (CVSFILE *, void *);
-static int cvs_annotate_pre_exec (struct cvsroot *);
+static int cvs_annotate_init(struct cvs_cmd *, int, char **, int *);
+static int cvs_annotate_remote(CVSFILE *, void *);
+static int cvs_annotate_local(CVSFILE *, void *);
+static int cvs_annotate_pre_exec(struct cvsroot *);
struct cvs_cmd cvs_cmd_annotate = {
CVS_OP_ANNOTATE, CVS_REQ_ANNOTATE, "annotate",
diff --git a/usr.bin/cvs/buf.c b/usr.bin/cvs/buf.c
index a86061a6438..93bd454237a 100644
--- a/usr.bin/cvs/buf.c
+++ b/usr.bin/cvs/buf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: buf.c,v 1.14 2005/07/20 16:14:55 xsa Exp $ */
+/* $OpenBSD: buf.c,v 1.15 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2003 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -40,27 +40,27 @@
#include "log.h"
-#define BUF_INCR 128
+#define BUF_INCR 128
struct cvs_buf {
- u_int cb_flags;
+ u_int cb_flags;
/* buffer handle and size */
- u_char *cb_buf;
- size_t cb_size;
+ u_char *cb_buf;
+ size_t cb_size;
/* start and length of valid data in buffer */
- u_char *cb_cur;
- size_t cb_len;
+ u_char *cb_cur;
+ size_t cb_len;
};
-#define SIZE_LEFT(b) ((size_t)(b->cb_buf - b->cb_cur) + b->cb_size)
+#define SIZE_LEFT(b) ((size_t)(b->cb_buf - b->cb_cur) + b->cb_size)
-static ssize_t cvs_buf_grow (BUF *, size_t);
+static ssize_t cvs_buf_grow(BUF *, size_t);
@@ -71,7 +71,7 @@ static ssize_t cvs_buf_grow (BUF *, size_t);
* uses dynamically-allocated memory and must be freed with cvs_buf_free(),
* once the buffer is no longer needed.
*/
-BUF*
+BUF *
cvs_buf_alloc(size_t len, u_int flags)
{
BUF *b;
@@ -106,7 +106,7 @@ cvs_buf_alloc(size_t len, u_int flags)
* buffer.
* Returns the loaded buffer on success, or NULL on failure.
*/
-BUF*
+BUF *
cvs_buf_load(const char *path, u_int flags)
{
int fd;
diff --git a/usr.bin/cvs/checkout.c b/usr.bin/cvs/checkout.c
index a205f5e4b6c..058fc64f184 100644
--- a/usr.bin/cvs/checkout.c
+++ b/usr.bin/cvs/checkout.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: checkout.c,v 1.38 2005/07/24 17:48:05 xsa Exp $ */
+/* $OpenBSD: checkout.c,v 1.39 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -38,11 +38,11 @@
#include "proto.h"
-#define CVS_LISTMOD 1
-#define CVS_STATMOD 2
+#define CVS_LISTMOD 1
+#define CVS_STATMOD 2
-static int cvs_checkout_init (struct cvs_cmd *, int, char **, int *);
-static int cvs_checkout_pre_exec (struct cvsroot *);
+static int cvs_checkout_init(struct cvs_cmd *, int, char **, int *);
+static int cvs_checkout_pre_exec(struct cvsroot *);
struct cvs_cmd cvs_cmd_checkout = {
CVS_OP_CHECKOUT, CVS_REQ_CO, "checkout",
diff --git a/usr.bin/cvs/cmd.c b/usr.bin/cvs/cmd.c
index b32f2c19099..11c8d155842 100644
--- a/usr.bin/cvs/cmd.c
+++ b/usr.bin/cvs/cmd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd.c,v 1.31 2005/07/23 11:19:46 joris Exp $ */
+/* $OpenBSD: cmd.c,v 1.32 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2005 Joris Vink <joris@openbsd.org>
* All rights reserved.
@@ -96,7 +96,7 @@ struct cvs_cmd *cvs_cdt[] = {
* aliases matches <cmd>.
* Returns a pointer to the command entry on success, NULL on failure.
*/
-struct cvs_cmd*
+struct cvs_cmd *
cvs_findcmd(const char *cmd)
{
int i, j;
@@ -121,7 +121,7 @@ cvs_findcmd(const char *cmd)
return (cmdp);
}
-struct cvs_cmd*
+struct cvs_cmd *
cvs_findcmdbyreq(int reqid)
{
int i;
diff --git a/usr.bin/cvs/commit.c b/usr.bin/cvs/commit.c
index a269133e003..e2ac9720dcd 100644
--- a/usr.bin/cvs/commit.c
+++ b/usr.bin/cvs/commit.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: commit.c,v 1.44 2005/07/23 11:19:46 joris Exp $ */
+/* $OpenBSD: commit.c,v 1.45 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -41,11 +41,11 @@
#include "proto.h"
-static int cvs_commit_init (struct cvs_cmd *, int, char **, int *);
-static int cvs_commit_prepare (CVSFILE *, void *);
-static int cvs_commit_remote (CVSFILE *, void *);
-static int cvs_commit_local (CVSFILE *, void *);
-static int cvs_commit_pre_exec(struct cvsroot *);
+static int cvs_commit_init(struct cvs_cmd *, int, char **, int *);
+static int cvs_commit_prepare(CVSFILE *, void *);
+static int cvs_commit_remote(CVSFILE *, void *);
+static int cvs_commit_local(CVSFILE *, void *);
+static int cvs_commit_pre_exec(struct cvsroot *);
struct cvs_cmd cvs_cmd_commit = {
CVS_OP_COMMIT, CVS_REQ_CI, "commit",
diff --git a/usr.bin/cvs/cvs.c b/usr.bin/cvs/cvs.c
index fe1910de224..11e78dbe6ba 100644
--- a/usr.bin/cvs/cvs.c
+++ b/usr.bin/cvs/cvs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cvs.c,v 1.74 2005/07/24 17:48:05 xsa Exp $ */
+/* $OpenBSD: cvs.c,v 1.75 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -73,9 +73,9 @@ CVSFILE *cvs_files;
static TAILQ_HEAD(, cvs_var) cvs_variables;
-void usage (void);
-static void cvs_read_rcfile (void);
-int cvs_getopt(int, char **);
+void usage(void);
+static void cvs_read_rcfile(void);
+int cvs_getopt(int, char **);
/*
* usage()
@@ -514,7 +514,7 @@ cvs_var_unset(const char *var)
* value string on success, or NULL if the variable does not exist.
*/
-const char*
+const char *
cvs_var_get(const char *var)
{
struct cvs_var *vp;
diff --git a/usr.bin/cvs/diff.c b/usr.bin/cvs/diff.c
index 46e985e250f..7e64e156e14 100644
--- a/usr.bin/cvs/diff.c
+++ b/usr.bin/cvs/diff.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: diff.c,v 1.52 2005/07/22 16:27:29 joris Exp $ */
+/* $OpenBSD: diff.c,v 1.53 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (C) Caldera International Inc. 2001-2002.
* All rights reserved.
@@ -147,7 +147,7 @@
#include "proto.h"
-#define CVS_DIFF_DEFCTX 3 /* default context length */
+#define CVS_DIFF_DEFCTX 3 /* default context length */
/*
@@ -175,14 +175,14 @@
#define D_SKIPPED2 9 /* path2 was a special file */
struct cand {
- int x;
- int y;
- int pred;
+ int x;
+ int y;
+ int pred;
} cand;
struct line {
- int serial;
- int value;
+ int serial;
+ int value;
} *file[2];
/*
@@ -191,52 +191,53 @@ struct line {
* understand the highly mnemonic field names)
*/
struct context_vec {
- int a; /* start line in old file */
- int b; /* end line in old file */
- int c; /* start line in new file */
- int d; /* end line in new file */
+ int a; /* start line in old file */
+ int b; /* end line in old file */
+ int c; /* start line in new file */
+ int d; /* end line in new file */
};
struct diff_arg {
- char *rev1;
- char *rev2;
- char *date1;
- char *date2;
+ char *rev1;
+ char *rev2;
+ char *date1;
+ char *date2;
};
-static int cvs_diff_init (struct cvs_cmd *, int, char **, int *);
-static int cvs_diff_remote (CVSFILE *, void *);
-static int cvs_diff_local (CVSFILE *, void *);
-static int cvs_diff_pre_exec (struct cvsroot *);
-static int cvs_diff_cleanup (void);
-int cvs_diffreg (const char *, const char *);
-
-static void output(const char *, FILE *, const char *, FILE *);
-static void check(FILE *, FILE *);
-static void range(int, int, char *);
-static void uni_range(int, int);
-static void dump_context_vec(FILE *, FILE *);
-static void dump_unified_vec(FILE *, FILE *);
-static int prepare(int, FILE *, off_t);
-static void prune(void);
-static void equiv(struct line *, int, struct line *, int, int *);
-static void unravel(int);
-static void unsort(struct line *, int, int *);
-static void change(const char *, FILE *, const char *, FILE *, int, int, int, int);
-static void sort(struct line *, int);
-static int ignoreline(char *);
-static int asciifile(FILE *);
-static int fetch(long *, int, int, FILE *, int, int);
-static int newcand(int, int, int);
-static int search(int *, int, int);
-static int skipline(FILE *);
-static int isqrt(int);
-static int stone(int *, int, int *, int *);
-static int readhash(FILE *);
-static int files_differ(FILE *, FILE *);
-static char *match_function(const long *, int, FILE *);
-static char *preadline(int, size_t, off_t);
+static int cvs_diff_init(struct cvs_cmd *, int, char **, int *);
+static int cvs_diff_remote(CVSFILE *, void *);
+static int cvs_diff_local(CVSFILE *, void *);
+static int cvs_diff_pre_exec(struct cvsroot *);
+static int cvs_diff_cleanup(void);
+int cvs_diffreg(const char *, const char *);
+
+static void output(const char *, FILE *, const char *, FILE *);
+static void check(FILE *, FILE *);
+static void range(int, int, char *);
+static void uni_range(int, int);
+static void dump_context_vec(FILE *, FILE *);
+static void dump_unified_vec(FILE *, FILE *);
+static int prepare(int, FILE *, off_t);
+static void prune(void);
+static void equiv(struct line *, int, struct line *, int, int *);
+static void unravel(int);
+static void unsort(struct line *, int, int *);
+static void change(const char *, FILE *, const char *, FILE *, int,
+ int, int, int);
+static void sort(struct line *, int);
+static int ignoreline(char *);
+static int asciifile(FILE *);
+static int fetch(long *, int, int, FILE *, int, int);
+static int newcand(int, int, int);
+static int search(int *, int, int);
+static int skipline(FILE *);
+static int isqrt(int);
+static int stone(int *, int, int *, int *);
+static int readhash(FILE *);
+static int files_differ(FILE *, FILE *);
+static char *match_function(const long *, int, FILE *);
+static char *preadline(int, size_t, off_t);
static int aflag, bflag, dflag, iflag, Nflag, pflag, tflag, Tflag, wflag;
diff --git a/usr.bin/cvs/edit.c b/usr.bin/cvs/edit.c
index 787094ae3ce..3f92722e59d 100644
--- a/usr.bin/cvs/edit.c
+++ b/usr.bin/cvs/edit.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: edit.c,v 1.7 2005/07/10 21:51:23 joris Exp $ */
+/* $OpenBSD: edit.c,v 1.8 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2005 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -40,9 +40,9 @@
-static int cvs_edit_init (struct cvs_cmd *, int, char **, int *);
-static int cvs_edit_remote (CVSFILE *, void *);
-static int cvs_edit_local (CVSFILE *, void *);
+static int cvs_edit_init(struct cvs_cmd *, int, char **, int *);
+static int cvs_edit_remote(CVSFILE *, void *);
+static int cvs_edit_local(CVSFILE *, void *);
struct cvs_cmd cvs_cmd_edit = {
diff --git a/usr.bin/cvs/entries.c b/usr.bin/cvs/entries.c
index 1d9a9e71fde..94de7b16275 100644
--- a/usr.bin/cvs/entries.c
+++ b/usr.bin/cvs/entries.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: entries.c,v 1.41 2005/07/24 16:46:39 xsa Exp $ */
+/* $OpenBSD: entries.c,v 1.42 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -37,8 +37,8 @@
#include "log.h"
-#define CVS_ENTRIES_NFIELDS 6
-#define CVS_ENTRIES_DELIM '/'
+#define CVS_ENTRIES_NFIELDS 6
+#define CVS_ENTRIES_DELIM '/'
/*
@@ -48,7 +48,7 @@
* Returns a pointer to the CVSENTRIES file structure on success, or NULL
* on failure.
*/
-CVSENTRIES*
+CVSENTRIES *
cvs_ent_open(const char *dir, int flags)
{
size_t len;
@@ -285,7 +285,7 @@ cvs_ent_remove(CVSENTRIES *ef, const char *name)
* <file>.
* Returns a pointer to the cvs entry structure on success, or NULL on failure.
*/
-struct cvs_ent*
+struct cvs_ent *
cvs_ent_get(CVSENTRIES *ef, const char *file)
{
struct cvs_ent *ent;
@@ -306,7 +306,7 @@ cvs_ent_get(CVSENTRIES *ef, const char *file)
* will return the entry following the last one returned.
* Returns a pointer to the cvs entry structure on success, or NULL on failure.
*/
-struct cvs_ent*
+struct cvs_ent *
cvs_ent_next(CVSENTRIES *ef)
{
if (ef->cef_cur == NULL)
diff --git a/usr.bin/cvs/file.c b/usr.bin/cvs/file.c
index 9d19291b5ad..c7194906efd 100644
--- a/usr.bin/cvs/file.c
+++ b/usr.bin/cvs/file.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: file.c,v 1.103 2005/07/24 19:04:55 joris Exp $ */
+/* $OpenBSD: file.c,v 1.104 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -44,16 +44,16 @@
#include "log.h"
#include "strtab.h"
-#define CVS_IGN_STATIC 0x01 /* pattern is static, no need to glob */
+#define CVS_IGN_STATIC 0x01 /* pattern is static, no need to glob */
-#define CVS_CHAR_ISMETA(c) ((c == '*') || (c == '?') || (c == '['))
+#define CVS_CHAR_ISMETA(c) ((c == '*') || (c == '?') || (c == '['))
/* ignore pattern */
struct cvs_ignpat {
- char ip_pat[MAXNAMLEN];
- int ip_flags;
- TAILQ_ENTRY (cvs_ignpat) ip_list;
+ char ip_pat[MAXNAMLEN];
+ int ip_flags;
+ TAILQ_ENTRY (cvs_ignpat) ip_list;
};
@@ -104,17 +104,17 @@ static const char *cvs_ign_std[] = {
static RCSNUM *cvs_addedrev;
-TAILQ_HEAD(, cvs_ignpat) cvs_ign_pats;
+TAILQ_HEAD(, cvs_ignpat) cvs_ign_pats;
static int cvs_file_getdir(CVSFILE *, int, int (*)(CVSFILE *, void *),
void *, int);
-static int cvs_load_dirinfo (CVSFILE *, int);
-static int cvs_file_sort (struct cvs_flist *, u_int);
-static int cvs_file_cmp (const void *, const void *);
-static int cvs_file_cmpname (const char *, const char *);
-static CVSFILE* cvs_file_alloc (const char *, u_int);
-static CVSFILE* cvs_file_lget (const char *, int, CVSFILE *, struct cvs_ent *);
+static int cvs_load_dirinfo(CVSFILE *, int);
+static int cvs_file_sort(struct cvs_flist *, u_int);
+static int cvs_file_cmp(const void *, const void *);
+static int cvs_file_cmpname(const char *, const char *);
+static CVSFILE *cvs_file_alloc(const char *, u_int);
+static CVSFILE *cvs_file_lget(const char *, int, CVSFILE *, struct cvs_ent *);
/*
@@ -701,7 +701,7 @@ cvs_file_find(CVSFILE *hier, const char *path)
* at least MAXPATHLEN bytes long.
* Returns a pointer to the start of the path.
*/
-char*
+char *
cvs_file_getpath(CVSFILE *file, char *buf, size_t len)
{
memset(buf, '\0', len);
diff --git a/usr.bin/cvs/getlog.c b/usr.bin/cvs/getlog.c
index ca49e535997..a4af478a8ce 100644
--- a/usr.bin/cvs/getlog.c
+++ b/usr.bin/cvs/getlog.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: getlog.c,v 1.42 2005/07/22 16:27:29 joris Exp $ */
+/* $OpenBSD: getlog.c,v 1.43 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -36,18 +36,18 @@
#include "proto.h"
-#define CVS_GLOG_RFONLY 0x01
-#define CVS_GLOG_HDONLY 0x02
+#define CVS_GLOG_RFONLY 0x01
+#define CVS_GLOG_HDONLY 0x02
-#define CVS_GETLOG_REVSEP "----------------------------"
+#define CVS_GETLOG_REVSEP "----------------------------"
#define CVS_GETLOG_REVEND \
"============================================================================="
-static int cvs_getlog_init (struct cvs_cmd *, int, char **, int *);
-static int cvs_getlog_remote (CVSFILE *, void *);
-static int cvs_getlog_local (CVSFILE *, void *);
-static int cvs_getlog_pre_exec (struct cvsroot *);
+static int cvs_getlog_init(struct cvs_cmd *, int, char **, int *);
+static int cvs_getlog_remote(CVSFILE *, void *);
+static int cvs_getlog_local(CVSFILE *, void *);
+static int cvs_getlog_pre_exec(struct cvsroot *);
struct cvs_cmd cvs_cmd_log = {
CVS_OP_LOG, CVS_REQ_LOG, "log",
diff --git a/usr.bin/cvs/hist.c b/usr.bin/cvs/hist.c
index c81b6fecdaa..448254ba16d 100644
--- a/usr.bin/cvs/hist.c
+++ b/usr.bin/cvs/hist.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: hist.c,v 1.6 2005/07/21 11:42:24 xsa Exp $ */
+/* $OpenBSD: hist.c,v 1.7 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -35,12 +35,12 @@
#include "cvs.h"
#include "log.h"
-#define CVS_HIST_BUFSIZE 8192
+#define CVS_HIST_BUFSIZE 8192
-static int cvs_hist_fillbuf (CVSHIST *);
-static int cvs_hist_fmt (const struct cvs_hent *, char *, size_t);
+static int cvs_hist_fillbuf(CVSHIST *);
+static int cvs_hist_fmt(const struct cvs_hent *, char *, size_t);
/*
diff --git a/usr.bin/cvs/history.c b/usr.bin/cvs/history.c
index 2e698aa660a..887ae64a7ca 100644
--- a/usr.bin/cvs/history.c
+++ b/usr.bin/cvs/history.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: history.c,v 1.22 2005/07/21 11:42:24 xsa Exp $ */
+/* $OpenBSD: history.c,v 1.23 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -37,25 +37,25 @@
#include "log.h"
#include "proto.h"
-#define CVS_HISTORY_MAXMOD 16
+#define CVS_HISTORY_MAXMOD 16
/* history flags */
-#define CVS_HF_A 0x01
-#define CVS_HF_C 0x02
-#define CVS_HF_E 0x04
-#define CVS_HF_L 0x08
-#define CVS_HF_M 0x10
-#define CVS_HF_O 0x20
-#define CVS_HF_T 0x40
-#define CVS_HF_W 0x80
-
-#define CVS_HF_EXCL (CVS_HF_C|CVS_HF_E|CVS_HF_M|CVS_HF_O|CVS_HF_T|CVS_HF_X)
-
-static int cvs_history_init (struct cvs_cmd *, int, char **, int *);
+#define CVS_HF_A 0x01
+#define CVS_HF_C 0x02
+#define CVS_HF_E 0x04
+#define CVS_HF_L 0x08
+#define CVS_HF_M 0x10
+#define CVS_HF_O 0x20
+#define CVS_HF_T 0x40
+#define CVS_HF_W 0x80
+
+#define CVS_HF_EXCL (CVS_HF_C|CVS_HF_E|CVS_HF_M|CVS_HF_O|CVS_HF_T|CVS_HF_X)
+
+static int cvs_history_init(struct cvs_cmd *, int, char **, int *);
#if 0
-static void cvs_history_print (struct cvs_hent *);
+static void cvs_history_print(struct cvs_hent *);
#endif
-static int cvs_history_pre_exec (struct cvsroot *);
+static int cvs_history_pre_exec(struct cvsroot *);
extern char *__progname;
diff --git a/usr.bin/cvs/import.c b/usr.bin/cvs/import.c
index 9c634261899..0df1305eac1 100644
--- a/usr.bin/cvs/import.c
+++ b/usr.bin/cvs/import.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: import.c,v 1.24 2005/07/15 12:24:50 xsa Exp $ */
+/* $OpenBSD: import.c,v 1.25 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Joris Vink <joris@openbsd.org>
* All rights reserved.
@@ -38,16 +38,16 @@
#include "proto.h"
-#define CVS_IMPORT_DEFBRANCH "1.1.1"
+#define CVS_IMPORT_DEFBRANCH "1.1.1"
-static int cvs_import_init (struct cvs_cmd *, int, char **, int *);
-static int cvs_import_pre_exec (struct cvsroot *);
-static int cvs_import_pre_exec (struct cvsroot *);
-static int cvs_import_post_exec(struct cvsroot *);
-static int cvs_import_remote (CVSFILE *, void *);
-static int cvs_import_local (CVSFILE *, void *);
-static int cvs_import_cleanup (void);
+static int cvs_import_init(struct cvs_cmd *, int, char **, int *);
+static int cvs_import_pre_exec(struct cvsroot *);
+static int cvs_import_pre_exec(struct cvsroot *);
+static int cvs_import_post_exec(struct cvsroot *);
+static int cvs_import_remote(CVSFILE *, void *);
+static int cvs_import_local(CVSFILE *, void *);
+static int cvs_import_cleanup(void);
static int dflag = 0;
static int conflicts = 0;
diff --git a/usr.bin/cvs/init.c b/usr.bin/cvs/init.c
index c1e5ab78eff..e229fd8395d 100644
--- a/usr.bin/cvs/init.c
+++ b/usr.bin/cvs/init.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: init.c,v 1.18 2005/07/19 15:30:37 xsa Exp $ */
+/* $OpenBSD: init.c,v 1.19 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -39,14 +39,14 @@
#include "proto.h"
-#define CFT_FILE 1
-#define CFT_DIR 2
+#define CFT_FILE 1
+#define CFT_DIR 2
struct cvsroot_file {
- char *cf_path; /* path relative to CVS root directory */
- u_int cf_type;
- mode_t cf_mode;
+ char *cf_path; /* path relative to CVS root directory */
+ u_int cf_type;
+ mode_t cf_mode;
} cvsroot_files[] = {
{ CVS_PATH_ROOT, CFT_DIR, (S_IRWXU|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH) },
{ CVS_PATH_EMPTYDIR, CFT_DIR, (S_IRWXU|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH) },
@@ -64,8 +64,8 @@ struct cvsroot_file {
{ CVS_PATH_VERIFYMSG, CFT_FILE, (S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH) },
};
-static int cvs_init_pre_exec (struct cvsroot *);
-static int cvs_init_create_files (struct cvsroot *);
+static int cvs_init_pre_exec(struct cvsroot *);
+static int cvs_init_create_files(struct cvsroot *);
struct cvs_cmd cvs_cmd_init = {
CVS_OP_INIT, CVS_REQ_INIT, "init",
diff --git a/usr.bin/cvs/logmsg.c b/usr.bin/cvs/logmsg.c
index 55df52bb46b..051e734f81c 100644
--- a/usr.bin/cvs/logmsg.c
+++ b/usr.bin/cvs/logmsg.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: logmsg.c,v 1.16 2005/07/23 00:03:00 joris Exp $ */
+/* $OpenBSD: logmsg.c,v 1.17 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -60,7 +60,7 @@ static const char *cvs_logmsg_ops[3] = {
* The returned value must later be free()d.
* Returns a pointer to the allocated buffer on success, or NULL on failure.
*/
-char*
+char *
cvs_logmsg_open(const char *path)
{
int lcont;
@@ -164,7 +164,7 @@ cvs_logmsg_open(const char *path)
* Returns the message in a dynamically allocated string on success, NULL on
* failure.
*/
-char*
+char *
cvs_logmsg_get(const char *dir, struct cvs_flist *added,
struct cvs_flist *modified, struct cvs_flist *removed)
{
diff --git a/usr.bin/cvs/proto.c b/usr.bin/cvs/proto.c
index af3c3640255..a6b537f9994 100644
--- a/usr.bin/cvs/proto.c
+++ b/usr.bin/cvs/proto.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: proto.c,v 1.66 2005/07/24 16:46:40 xsa Exp $ */
+/* $OpenBSD: proto.c,v 1.67 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -412,7 +412,7 @@ cvs_req_getbyname(const char *rname)
* Build a space-separated list of all the requests that this protocol
* implementation supports.
*/
-char*
+char *
cvs_req_getvalid(void)
{
u_int i;
@@ -476,7 +476,7 @@ cvs_resp_getbyid(int respid)
/*
* cvs_resp_getbyname()
*/
-struct cvs_resp*
+struct cvs_resp *
cvs_resp_getbyname(const char *rname)
{
u_int i;
@@ -495,7 +495,7 @@ cvs_resp_getbyname(const char *rname)
* Build a space-separated list of all the responses that this protocol
* implementation supports.
*/
-char*
+char *
cvs_resp_getvalid(void)
{
u_int i;
diff --git a/usr.bin/cvs/rcs.c b/usr.bin/cvs/rcs.c
index 3bb58ebd8b8..ddab7f05f99 100644
--- a/usr.bin/cvs/rcs.c
+++ b/usr.bin/cvs/rcs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rcs.c,v 1.56 2005/07/07 14:27:57 joris Exp $ */
+/* $OpenBSD: rcs.c,v 1.57 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -40,76 +40,76 @@
#include "rcs.h"
#include "strtab.h"
-#define RCS_BUFSIZE 16384
-#define RCS_BUFEXTSIZE 8192
+#define RCS_BUFSIZE 16384
+#define RCS_BUFEXTSIZE 8192
/* RCS token types */
-#define RCS_TOK_ERR -1
-#define RCS_TOK_EOF 0
-#define RCS_TOK_NUM 1
-#define RCS_TOK_ID 2
-#define RCS_TOK_STRING 3
-#define RCS_TOK_SCOLON 4
-#define RCS_TOK_COLON 5
-
-
-#define RCS_TOK_HEAD 8
-#define RCS_TOK_BRANCH 9
-#define RCS_TOK_ACCESS 10
-#define RCS_TOK_SYMBOLS 11
-#define RCS_TOK_LOCKS 12
-#define RCS_TOK_COMMENT 13
-#define RCS_TOK_EXPAND 14
-#define RCS_TOK_DATE 15
-#define RCS_TOK_AUTHOR 16
-#define RCS_TOK_STATE 17
-#define RCS_TOK_NEXT 18
-#define RCS_TOK_BRANCHES 19
-#define RCS_TOK_DESC 20
-#define RCS_TOK_LOG 21
-#define RCS_TOK_TEXT 22
-#define RCS_TOK_STRICT 23
-
-#define RCS_ISKEY(t) (((t) >= RCS_TOK_HEAD) && ((t) <= RCS_TOK_BRANCHES))
-
-
-#define RCS_NOSCOL 0x01 /* no terminating semi-colon */
-#define RCS_VOPT 0x02 /* value is optional */
+#define RCS_TOK_ERR -1
+#define RCS_TOK_EOF 0
+#define RCS_TOK_NUM 1
+#define RCS_TOK_ID 2
+#define RCS_TOK_STRING 3
+#define RCS_TOK_SCOLON 4
+#define RCS_TOK_COLON 5
+
+
+#define RCS_TOK_HEAD 8
+#define RCS_TOK_BRANCH 9
+#define RCS_TOK_ACCESS 10
+#define RCS_TOK_SYMBOLS 11
+#define RCS_TOK_LOCKS 12
+#define RCS_TOK_COMMENT 13
+#define RCS_TOK_EXPAND 14
+#define RCS_TOK_DATE 15
+#define RCS_TOK_AUTHOR 16
+#define RCS_TOK_STATE 17
+#define RCS_TOK_NEXT 18
+#define RCS_TOK_BRANCHES 19
+#define RCS_TOK_DESC 20
+#define RCS_TOK_LOG 21
+#define RCS_TOK_TEXT 22
+#define RCS_TOK_STRICT 23
+
+#define RCS_ISKEY(t) (((t) >= RCS_TOK_HEAD) && ((t) <= RCS_TOK_BRANCHES))
+
+
+#define RCS_NOSCOL 0x01 /* no terminating semi-colon */
+#define RCS_VOPT 0x02 /* value is optional */
/* opaque parse data */
struct rcs_pdata {
- u_int rp_lines;
+ u_int rp_lines;
- char *rp_buf;
- size_t rp_blen;
- char *rp_bufend;
- size_t rp_tlen;
+ char *rp_buf;
+ size_t rp_blen;
+ char *rp_bufend;
+ size_t rp_tlen;
/* pushback token buffer */
- char rp_ptok[128];
- int rp_pttype; /* token type, RCS_TOK_ERR if no token */
+ char rp_ptok[128];
+ int rp_pttype; /* token type, RCS_TOK_ERR if no token */
- FILE *rp_file;
+ FILE *rp_file;
};
struct rcs_line {
- char *rl_line;
- int rl_lineno;
- TAILQ_ENTRY(rcs_line) rl_list;
+ char *rl_line;
+ int rl_lineno;
+ TAILQ_ENTRY(rcs_line) rl_list;
};
TAILQ_HEAD(rcs_tqh, rcs_line);
struct rcs_foo {
- int rl_nblines;
- char *rl_data;
- struct rcs_tqh rl_lines;
+ int rl_nblines;
+ char *rl_data;
+ struct rcs_tqh rl_lines;
};
-#define RCS_TOKSTR(rfp) ((struct rcs_pdata *)rfp->rf_pdata)->rp_buf
-#define RCS_TOKLEN(rfp) ((struct rcs_pdata *)rfp->rf_pdata)->rp_tlen
+#define RCS_TOKSTR(rfp) ((struct rcs_pdata *)rfp->rf_pdata)->rp_buf
+#define RCS_TOKLEN(rfp) ((struct rcs_pdata *)rfp->rf_pdata)->rp_tlen
@@ -119,8 +119,8 @@ static const char rcs_sym_invch[] = RCS_SYM_INVALCHAR;
/* comment leaders, depending on the file's suffix */
static const struct rcs_comment {
- const char *rc_suffix;
- const char *rc_cstr;
+ const char *rc_suffix;
+ const char *rc_cstr;
} rcs_comments[] = {
{ "1", ".\\\" " },
{ "2", ".\\\" " },
@@ -186,12 +186,12 @@ static const struct rcs_comment {
{ "yr", " * " }, /* yacc-ratfor */
};
-#define NB_COMTYPES (sizeof(rcs_comments)/sizeof(rcs_comments[0]))
+#define NB_COMTYPES (sizeof(rcs_comments)/sizeof(rcs_comments[0]))
#ifdef notyet
static struct rcs_kfl {
- char rk_char;
- int rk_val;
+ char rk_char;
+ int rk_val;
} rcs_kflags[] = {
{ 'k', RCS_KWEXP_NAME },
{ 'v', RCS_KWEXP_VAL },
@@ -202,10 +202,10 @@ static struct rcs_kfl {
#endif
static struct rcs_key {
- char rk_str[16];
- int rk_id;
- int rk_val;
- int rk_flags;
+ char rk_str[16];
+ int rk_id;
+ int rk_val;
+ int rk_flags;
} rcs_keys[] = {
{ "access", RCS_TOK_ACCESS, RCS_TOK_ID, RCS_VOPT },
{ "author", RCS_TOK_AUTHOR, RCS_TOK_ID, 0 },
@@ -225,14 +225,14 @@ static struct rcs_key {
{ "text", RCS_TOK_TEXT, RCS_TOK_STRING, RCS_NOSCOL },
};
-#define RCS_NKEYS (sizeof(rcs_keys)/sizeof(rcs_keys[0]))
+#define RCS_NKEYS (sizeof(rcs_keys)/sizeof(rcs_keys[0]))
#ifdef notyet
/*
* Keyword expansion table
*/
static struct rcs_kw {
- char kw_str[16];
+ char kw_str[16];
} rcs_expkw[] = {
{ "Author" },
{ "Date" },
@@ -262,27 +262,27 @@ static const char *rcs_errstrs[] = {
int rcs_errno = RCS_ERR_NOERR;
-static int rcs_write (RCSFILE *);
-static int rcs_parse (RCSFILE *);
-static int rcs_parse_admin (RCSFILE *);
-static int rcs_parse_delta (RCSFILE *);
-static int rcs_parse_deltatext (RCSFILE *);
+static int rcs_write(RCSFILE *);
+static int rcs_parse(RCSFILE *);
+static int rcs_parse_admin(RCSFILE *);
+static int rcs_parse_delta(RCSFILE *);
+static int rcs_parse_deltatext(RCSFILE *);
-static int rcs_parse_access (RCSFILE *);
-static int rcs_parse_symbols (RCSFILE *);
-static int rcs_parse_locks (RCSFILE *);
-static int rcs_parse_branches (RCSFILE *, struct rcs_delta *);
-static void rcs_freedelta (struct rcs_delta *);
-static void rcs_freepdata (struct rcs_pdata *);
-static int rcs_gettok (RCSFILE *);
-static int rcs_pushtok (RCSFILE *, const char *, int);
-static int rcs_growbuf (RCSFILE *);
-static int rcs_patch_lines (struct rcs_foo *, struct rcs_foo *);
-static int rcs_strprint (const u_char *, size_t, FILE *);
+static int rcs_parse_access(RCSFILE *);
+static int rcs_parse_symbols(RCSFILE *);
+static int rcs_parse_locks(RCSFILE *);
+static int rcs_parse_branches(RCSFILE *, struct rcs_delta *);
+static void rcs_freedelta(struct rcs_delta *);
+static void rcs_freepdata(struct rcs_pdata *);
+static int rcs_gettok(RCSFILE *);
+static int rcs_pushtok(RCSFILE *, const char *, int);
+static int rcs_growbuf(RCSFILE *);
+static int rcs_patch_lines(struct rcs_foo *, struct rcs_foo *);
+static int rcs_strprint(const u_char *, size_t, FILE *);
-static struct rcs_delta* rcs_findrev (RCSFILE *, const RCSNUM *);
-static struct rcs_foo* rcs_splitlines (const char *);
-static void rcs_freefoo (struct rcs_foo *);
+static struct rcs_delta *rcs_findrev(RCSFILE *, const RCSNUM *);
+static struct rcs_foo *rcs_splitlines(const char *);
+static void rcs_freefoo(struct rcs_foo *);
/*
@@ -933,7 +933,7 @@ rcs_lock_remove(RCSFILE *file, const RCSNUM *rev)
*
* Retrieve the description for the RCS file <file>.
*/
-const char*
+const char *
rcs_desc_get(RCSFILE *file)
{
return (file->rf_desc);
@@ -967,7 +967,7 @@ rcs_desc_set(RCSFILE *file, const char *desc)
* Lookup the assumed comment leader based on a file's suffix.
* Returns a pointer to the string on success, or NULL on failure.
*/
-const char*
+const char *
rcs_comment_lookup(const char *filename)
{
int i;
@@ -990,7 +990,7 @@ rcs_comment_lookup(const char *filename)
*
* Retrieve the comment leader for the RCS file <file>.
*/
-const char*
+const char *
rcs_comment_get(RCSFILE *file)
{
return (file->rf_comment);
@@ -1490,7 +1490,7 @@ rcs_kflag_get(const char *flags)
*
* Get the error string matching the RCS error code <code>.
*/
-const char*
+const char *
rcs_errstr(int code)
{
const char *esp;
diff --git a/usr.bin/cvs/rcsnum.c b/usr.bin/cvs/rcsnum.c
index d5a140dcca2..985120a0333 100644
--- a/usr.bin/cvs/rcsnum.c
+++ b/usr.bin/cvs/rcsnum.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rcsnum.c,v 1.12 2005/05/31 08:58:48 xsa Exp $ */
+/* $OpenBSD: rcsnum.c,v 1.13 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -105,7 +105,7 @@ rcsnum_free(RCSNUM *rn)
* <blen>.
* Returns a pointer to the start of <buf> on success, or NULL on failure.
*/
-char*
+char *
rcsnum_tostr(const RCSNUM *nump, char *buf, size_t blen)
{
u_int i;
diff --git a/usr.bin/cvs/repo.c b/usr.bin/cvs/repo.c
index a1c5d6a54d7..387639d38e4 100644
--- a/usr.bin/cvs/repo.c
+++ b/usr.bin/cvs/repo.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: repo.c,v 1.5 2005/07/07 14:27:57 joris Exp $ */
+/* $OpenBSD: repo.c,v 1.6 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2005 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -425,7 +425,7 @@ cvs_repo_find(CVSREPO *repo, const char *path)
* at least MAXPATHLEN bytes long.
* Returns a pointer to the start of the path on success, or NULL on failure.
*/
-char*
+char *
cvs_repo_getpath(CVSRPENT *file, char *buf, size_t len)
{
u_int i;
diff --git a/usr.bin/cvs/resp.c b/usr.bin/cvs/resp.c
index 28ddf11ecc4..e36b72b2be1 100644
--- a/usr.bin/cvs/resp.c
+++ b/usr.bin/cvs/resp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: resp.c,v 1.49 2005/07/24 17:20:14 xsa Exp $ */
+/* $OpenBSD: resp.c,v 1.50 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -44,7 +44,7 @@
#include "proto.h"
-#define CVS_MTSTK_MAXDEPTH 16
+#define CVS_MTSTK_MAXDEPTH 16
#define STRIP_SLASH(p) \
diff --git a/usr.bin/cvs/root.c b/usr.bin/cvs/root.c
index 892482ca628..15426400c3c 100644
--- a/usr.bin/cvs/root.c
+++ b/usr.bin/cvs/root.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: root.c,v 1.19 2005/05/31 08:58:48 xsa Exp $ */
+/* $OpenBSD: root.c,v 1.20 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -54,7 +54,7 @@ const char *cvs_methods[] = {
"fork",
};
-#define CVS_NBMETHODS (sizeof(cvs_methods)/sizeof(cvs_methods[0]))
+#define CVS_NBMETHODS (sizeof(cvs_methods)/sizeof(cvs_methods[0]))
/*
* CVSROOT cache
diff --git a/usr.bin/cvs/strtab.c b/usr.bin/cvs/strtab.c
index 66898aae6ba..18c6465714a 100644
--- a/usr.bin/cvs/strtab.c
+++ b/usr.bin/cvs/strtab.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: strtab.c,v 1.5 2005/05/31 08:58:48 xsa Exp $ */
+/* $OpenBSD: strtab.c,v 1.6 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2005 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -42,26 +42,26 @@
#include "log.h"
#include "strtab.h"
-#define CVS_STRTAB_HASHBITS 8
-#define CVS_STRTAB_NBUCKETS (1 << CVS_STRTAB_HASHBITS)
-#define CVS_STRTAB_FNVPRIME 0x01000193
-#define CVS_STRTAB_FNVINIT 0x811c9dc5
+#define CVS_STRTAB_HASHBITS 8
+#define CVS_STRTAB_NBUCKETS (1 << CVS_STRTAB_HASHBITS)
+#define CVS_STRTAB_FNVPRIME 0x01000193
+#define CVS_STRTAB_FNVINIT 0x811c9dc5
struct cvs_str {
- char *cs_str;
- int cs_ref;
- SLIST_ENTRY(cvs_str) cs_link;
+ char *cs_str;
+ int cs_ref;
+ SLIST_ENTRY(cvs_str) cs_link;
};
SLIST_HEAD(cvs_slist, cvs_str);
-static struct cvs_slist cvs_strtab[CVS_STRTAB_NBUCKETS];
+static struct cvs_slist cvs_strtab[CVS_STRTAB_NBUCKETS];
-static struct cvs_str* cvs_strtab_insert (const char *);
-static struct cvs_str* cvs_strtab_lookup (const char *);
-static u_int32_t cvs_strtab_hash (const char *);
-static void cvs_strtab_free (const char *);
+static struct cvs_str *cvs_strtab_insert(const char *);
+static struct cvs_str *cvs_strtab_lookup(const char *);
+static u_int32_t cvs_strtab_hash(const char *);
+static void cvs_strtab_free(const char *);
@@ -70,7 +70,7 @@ static void cvs_strtab_free (const char *);
*
* Simple interface to the string table.
*/
-char*
+char *
cvs_strdup(const char *s)
{
struct cvs_str *csp;
diff --git a/usr.bin/cvs/util.c b/usr.bin/cvs/util.c
index fb5eb782cc9..4f43bb49b7e 100644
--- a/usr.bin/cvs/util.c
+++ b/usr.bin/cvs/util.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: util.c,v 1.41 2005/07/24 17:33:09 xsa Exp $ */
+/* $OpenBSD: util.c,v 1.42 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -367,7 +367,7 @@ cvs_getargv(const char *line, char **argv, int argvlen)
* Allocate an argument vector large enough to accommodate for all the
* arguments found in <line> and return it.
*/
-char**
+char **
cvs_makeargv(const char *line, int *argc)
{
int i, ret;
@@ -741,7 +741,7 @@ cvs_path_cat(const char *base, const char *end, char *dst, size_t dlen)
* at least MAXPATHLEN bytes long.
* Returns a pointer to the start of the path on success, or NULL on failure.
*/
-char*
+char *
cvs_rcs_getpath(CVSFILE *file, char *buf, size_t len)
{
int l;
diff --git a/usr.bin/cvs/zlib.c b/usr.bin/cvs/zlib.c
index 0f083ea8fd0..fb1bd30ee06 100644
--- a/usr.bin/cvs/zlib.c
+++ b/usr.bin/cvs/zlib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: zlib.c,v 1.2 2005/01/13 20:22:55 jfb Exp $ */
+/* $OpenBSD: zlib.c,v 1.3 2005/07/25 12:05:43 xsa Exp $ */
/*
* Copyright (c) 2005 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -33,12 +33,12 @@
#include "cvs.h"
#include "zlib.h"
-#define CVS_ZLIB_BUFSIZE 1024
+#define CVS_ZLIB_BUFSIZE 1024
struct cvs_zlib_ctx {
- int z_level;
- z_stream z_instrm;
- z_stream z_destrm;
+ int z_level;
+ z_stream z_instrm;
+ z_stream z_destrm;
};
@@ -49,7 +49,7 @@ struct cvs_zlib_ctx {
* of data with compression level <level>, which must be between 0 and 9. A
* value of 0 means no compression, and 9 is the highest level of compression.
*/
-CVSZCTX*
+CVSZCTX *
cvs_zlib_newctx(int level)
{
CVSZCTX *ctx;