diff --git a/external/bsd/byacc/dist/NOTES b/external/bsd/byacc/dist/NOTES index 9db3c96ce1b8..8d7599b9092c 100644 --- a/external/bsd/byacc/dist/NOTES +++ b/external/bsd/byacc/dist/NOTES @@ -1,3 +1,5 @@ +$NetBSD: NOTES,v 1.2 2009/10/29 00:56:19 christos Exp $ + Berkeley Yacc reflects its origins. The reason so many routines use exactly six register variables is that Berkeley Yacc was developed on a VAX using PCC. PCC placed at most six variables @@ -5,5 +7,15 @@ in registers. I went to considerable effort to find which six variables most belonged in registers. Changes in machines and compilers make that effort worthless, perhaps even harmful. +[Given the previous paragraph, and the fact that GCC does not respect + register declarations, and the fact that much of the rest of the + 4.4lite2 release had "register" declarations extirpated, I've removed + most of the register declarations from the code. I left them in the + generated skeleton code "for the hell of it" but they probably should + go from there, too. -- pm, July 1997] + +[I totally removed the register stuff; we've deprecated it elsewhere + in the tree now -- lukem, October 1997] + The code contains many instances where address calculations are performed in particular ways to optimize the code for the VAX. diff --git a/external/bsd/byacc/dist/closure.c b/external/bsd/byacc/dist/closure.c index 9bb82dcd0dcd..4fda60fc88d4 100644 --- a/external/bsd/byacc/dist/closure.c +++ b/external/bsd/byacc/dist/closure.c @@ -1,9 +1,11 @@ -/* $NetBSD: closure.c,v 1.1.1.1 2009/10/29 00:46:52 christos Exp $ */ - +/* $NetBSD: closure.c,v 1.2 2009/10/29 00:56:19 christos Exp $ */ /* Id: closure.c,v 1.7 2009/10/27 09:30:14 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: closure.c,v 1.2 2009/10/29 00:56:19 christos Exp $"); + Value_t *itemset; Value_t *itemsetend; unsigned *ruleset; diff --git a/external/bsd/byacc/dist/config_h.in b/external/bsd/byacc/dist/config_h.in index 833508fb40e1..93deffc29948 100644 --- a/external/bsd/byacc/dist/config_h.in +++ b/external/bsd/byacc/dist/config_h.in @@ -1,3 +1,3 @@ /* @configure_input@ */ -/* Id: config_h.in,v 1.1 1995/01/01 19:34:59 tom Exp */ +/* $Id: config_h.in,v 1.2 2009/10/29 00:56:19 christos Exp $ */ @DEFS@ diff --git a/external/bsd/byacc/dist/defs.h b/external/bsd/byacc/dist/defs.h index 0dabd4480eb9..ea9b6e122836 100644 --- a/external/bsd/byacc/dist/defs.h +++ b/external/bsd/byacc/dist/defs.h @@ -1,7 +1,9 @@ -/* $NetBSD: defs.h,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - /* Id: defs.h,v 1.20 2009/10/27 10:47:43 tom Exp */ +#if HAVE_NBTOOL_CONFIG_H +#include "nbtool_config.h" +#endif + #ifdef HAVE_CONFIG_H #include #endif @@ -222,15 +224,15 @@ extern int lineno; extern int outline; extern int exit_code; -extern const char *banner[]; -extern const char *tables[]; -extern const char *header[]; -extern const char *body[]; -extern const char *trailer[]; +extern const char * const banner[]; +extern const char * const tables[]; +extern const char * const header[]; +extern const char * const body[]; +extern const char * const trailer[]; extern char *code_file_name; extern char *defines_file_name; -extern char *input_file_name; +extern const char *input_file_name; extern char *output_file_name; extern char *verbose_file_name; extern char *graph_file_name; @@ -340,7 +342,7 @@ extern void reprec_warning(char *s); extern void restarted_warning(void); extern void retyped_warning(char *s); extern void revalued_warning(char *s); -extern void syntax_error(int st_lineno, char *st_line, char *st_cptr) GCC_NORETURN; +extern __dead void syntax_error(int st_lineno, char *st_line, char *st_cptr) GCC_NORETURN; extern void terminal_lhs(int s_lineno); extern void terminal_start(char *s); extern void tokenized_start(char *s); @@ -391,7 +393,7 @@ extern void output(void); extern void reader(void); /* skeleton.c */ -extern void write_section(const char *section[]); +extern void write_section(const char * const section[]); /* verbose.c */ extern void verbose(void); diff --git a/external/bsd/byacc/dist/error.c b/external/bsd/byacc/dist/error.c index 1364816d1085..8cff027d4ced 100644 --- a/external/bsd/byacc/dist/error.c +++ b/external/bsd/byacc/dist/error.c @@ -1,26 +1,28 @@ -/* $NetBSD: error.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: error.c,v 1.2 2009/10/29 00:56:19 christos Exp $ */ /* Id: error.c,v 1.6 2008/11/24 21:30:35 tom Exp */ -/* routines for printing error messages */ +#include +__RCSID("$NetBSD: error.c,v 1.2 2009/10/29 00:56:19 christos Exp $"); #include "defs.h" -void +/* routines for printing error messages */ + +__dead void fatal(const char *msg) { fprintf(stderr, "%s: f - %s\n", myname, msg); done(2); } -void +__dead void no_space(void) { fprintf(stderr, "%s: f - out of space\n", myname); done(2); } -void +__dead void open_error(const char *filename) { fprintf(stderr, "%s: f - cannot open \"%s\"\n", myname, filename); @@ -44,7 +46,7 @@ print_pos(char *st_line, char *st_cptr) return; for (s = st_line; *s != '\n'; ++s) { - if (isprint(*s) || *s == '\t') + if (isprint((unsigned char)*s) || *s == '\t') putc(*s, stderr); else putc('?', stderr); @@ -61,7 +63,7 @@ print_pos(char *st_line, char *st_cptr) putc('\n', stderr); } -void +__dead void syntax_error(int st_lineno, char *st_line, char *st_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", syntax error\n", @@ -70,7 +72,7 @@ syntax_error(int st_lineno, char *st_line, char *st_cptr) done(1); } -void +__dead void unterminated_comment(int c_lineno, char *c_line, char *c_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", unmatched /*\n", @@ -79,7 +81,7 @@ unterminated_comment(int c_lineno, char *c_line, char *c_cptr) done(1); } -void +__dead void unterminated_string(int s_lineno, char *s_line, char *s_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", unterminated string\n", @@ -88,7 +90,7 @@ unterminated_string(int s_lineno, char *s_line, char *s_cptr) done(1); } -void +__dead void unterminated_text(int t_lineno, char *t_line, char *t_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", unmatched %%{\n", @@ -97,7 +99,7 @@ unterminated_text(int t_lineno, char *t_line, char *t_cptr) done(1); } -void +__dead void unterminated_union(int u_lineno, char *u_line, char *u_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", unterminated %%union \ @@ -106,7 +108,7 @@ declaration\n", myname, u_lineno, input_file_name); done(1); } -void +__dead void over_unionized(char *u_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", too many %%union \ @@ -115,7 +117,7 @@ declarations\n", myname, lineno, input_file_name); done(1); } -void +__dead void illegal_tag(int t_lineno, char *t_line, char *t_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", illegal tag\n", @@ -124,7 +126,7 @@ illegal_tag(int t_lineno, char *t_line, char *t_cptr) done(1); } -void +__dead void illegal_character(char *c_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", illegal character\n", @@ -133,7 +135,7 @@ illegal_character(char *c_cptr) done(1); } -void +__dead void used_reserved(char *s) { fprintf(stderr, @@ -142,7 +144,7 @@ used_reserved(char *s) done(1); } -void +__dead void tokenized_start(char *s) { fprintf(stderr, @@ -227,7 +229,7 @@ dollar_warning(int a_lineno, int i) end of the current rule\n", myname, a_lineno, input_file_name, i); } -void +__dead void dollar_error(int a_lineno, char *a_line, char *a_cptr) { fprintf(stderr, "%s: e - line %d of \"%s\", illegal $-name\n", @@ -236,7 +238,7 @@ dollar_error(int a_lineno, char *a_line, char *a_cptr) done(1); } -void +__dead void untyped_lhs(void) { fprintf(stderr, "%s: e - line %d of \"%s\", $$ is untyped\n", @@ -244,7 +246,7 @@ untyped_lhs(void) done(1); } -void +__dead void untyped_rhs(int i, char *s) { fprintf(stderr, "%s: e - line %d of \"%s\", $%d (%s) is untyped\n", @@ -252,7 +254,7 @@ untyped_rhs(int i, char *s) done(1); } -void +__dead void unknown_rhs(int i) { fprintf(stderr, "%s: e - line %d of \"%s\", $%d is untyped\n", diff --git a/external/bsd/byacc/dist/graph.c b/external/bsd/byacc/dist/graph.c index f6763a989ea4..d7c992f81c88 100644 --- a/external/bsd/byacc/dist/graph.c +++ b/external/bsd/byacc/dist/graph.c @@ -1,9 +1,11 @@ -/* $NetBSD: graph.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: graph.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* Id: graph.c,v 1.7 2009/10/27 09:25:20 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: graph.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + static void graph_state(int stateno); static void graph_LA(int ruleno); diff --git a/external/bsd/byacc/dist/lalr.c b/external/bsd/byacc/dist/lalr.c index 276ade7e9d23..a1a614b9c776 100644 --- a/external/bsd/byacc/dist/lalr.c +++ b/external/bsd/byacc/dist/lalr.c @@ -1,9 +1,11 @@ -/* $NetBSD: lalr.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: lalr.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* Id: lalr.c,v 1.9 2009/10/27 09:49:27 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: lalr.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + typedef struct shorts { struct shorts *next; diff --git a/external/bsd/byacc/dist/lr0.c b/external/bsd/byacc/dist/lr0.c index fb4c979ca1dd..541643e183e2 100644 --- a/external/bsd/byacc/dist/lr0.c +++ b/external/bsd/byacc/dist/lr0.c @@ -1,9 +1,11 @@ -/* $NetBSD: lr0.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: lr0.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* Id: lr0.c,v 1.9 2009/10/27 09:20:39 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: lr0.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + static core *new_state(int symbol); static Value_t get_state(int symbol); static void allocate_itemsets(void); diff --git a/external/bsd/byacc/dist/main.c b/external/bsd/byacc/dist/main.c index 4d67737a727d..b457b533c22a 100644 --- a/external/bsd/byacc/dist/main.c +++ b/external/bsd/byacc/dist/main.c @@ -1,11 +1,14 @@ -/* $NetBSD: main.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: main.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* Id: main.c,v 1.23 2009/10/27 09:06:44 tom Exp */ +#include "defs.h" + +#include +__RCSID("$NetBSD: main.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + #include #include /* for _exit() */ -#include "defs.h" char dflag; char gflag; @@ -22,16 +25,18 @@ int lineno; int outline; static char empty_string[] = ""; -static char default_file_prefix[] = "y"; +static const char default_file_prefix[] = "y"; +static int explicit_file_name; -static char *file_prefix = default_file_prefix; +static const char *file_prefix = default_file_prefix; char *code_file_name; char *defines_file_name; -char *input_file_name = empty_string; +const char *input_file_name = empty_string; char *output_file_name = 0; char *verbose_file_name; char *graph_file_name; +char *allocated_file_prefix; FILE *action_file; /* a temp file, used to save actions associated */ /* with rules until the parser is written */ @@ -258,6 +263,7 @@ getargs(int argc, char *argv[]) output_file_name = argv[i]; else usage(); + explicit_file_name = 1; continue; case 'p': @@ -338,10 +344,10 @@ create_file_names(void) if (prefix != NULL) { len = (size_t) (prefix - output_file_name); - file_prefix = (char *)MALLOC(len + 1); + file_prefix = allocated_file_prefix = MALLOC(len + 1); if (file_prefix == 0) no_space(); - strncpy(file_prefix, output_file_name, len)[len] = 0; + strlcpy(allocated_file_prefix, output_file_name, len + 1); } else len = strlen(file_prefix); @@ -362,6 +368,35 @@ create_file_names(void) if (dflag) { + if (explicit_file_name) + { + char *suffix; + defines_file_name = strdup(output_file_name); + if (defines_file_name == 0) + no_space(); + /* does the output_file_name have a known suffix */ + suffix = strrchr(output_file_name, '.'); + if (suffix != 0 && + (!strcmp(suffix, ".c") || /* good, old-fashioned C */ + !strcmp(suffix, ".C") || /* C++, or C on Windows */ + !strcmp(suffix, ".cc") || /* C++ */ + !strcmp(suffix, ".cxx") || /* C++ */ + !strcmp(suffix, ".cpp"))) /* C++ (Windows) */ + { + strncpy(defines_file_name, output_file_name, + suffix - output_file_name + 1); + defines_file_name[suffix - output_file_name + 1] = 'h'; + defines_file_name[suffix - output_file_name + 2] = 0; + } else { + fprintf(stderr,"%s: suffix of output file name %s" + " not recognized, no -d file generated.\n", + myname, output_file_name); + dflag = 0; + free(defines_file_name); + defines_file_name = 0; + } + } + } else { CREATE_FILE_NAME(defines_file_name, defines_suffix); } @@ -375,9 +410,9 @@ create_file_names(void) CREATE_FILE_NAME(graph_file_name, GRAPH_SUFFIX); } - if (prefix != NULL) + if (allocated_file_prefix != NULL) { - FREE(file_prefix); + FREE(allocated_file_prefix); } } diff --git a/external/bsd/byacc/dist/mkpar.c b/external/bsd/byacc/dist/mkpar.c index bcb0fb7814da..b7a970ff0b5c 100644 --- a/external/bsd/byacc/dist/mkpar.c +++ b/external/bsd/byacc/dist/mkpar.c @@ -1,9 +1,11 @@ -/* $NetBSD: mkpar.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: mkpar.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* Id: mkpar.c,v 1.10 2009/10/27 10:50:13 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: mkpar.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + static action *add_reduce(action *actions, int ruleno, int symbol); static action *add_reductions(int stateno, action *actions); static action *get_shifts(int stateno); diff --git a/external/bsd/byacc/dist/output.c b/external/bsd/byacc/dist/output.c index dffa4671eeba..c421b4b39bd1 100644 --- a/external/bsd/byacc/dist/output.c +++ b/external/bsd/byacc/dist/output.c @@ -1,9 +1,11 @@ -/* $NetBSD: output.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: output.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* Id: output.c,v 1.21 2009/10/27 10:55:05 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: output.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + static int nvectors; static int nentries; static Value_t **froms; diff --git a/external/bsd/byacc/dist/reader.c b/external/bsd/byacc/dist/reader.c index aa43eb18070f..20eb9c5136be 100644 --- a/external/bsd/byacc/dist/reader.c +++ b/external/bsd/byacc/dist/reader.c @@ -1,9 +1,11 @@ -/* $NetBSD: reader.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: reader.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* Id: reader.c,v 1.18 2009/10/27 09:04:07 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: reader.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + /* The line size must be a positive integer. One hundred was chosen */ /* because few lines in Yacc input grammars exceed 100 characters. */ /* Note that if a line exceeds LINESIZE characters, the line buffer */ @@ -816,10 +818,10 @@ is_reserved(char *name) strcmp(name, "$end") == 0) return (1); - if (name[0] == '$' && name[1] == '$' && isdigit(name[2])) + if (name[0] == '$' && name[1] == '$' && isdigit((unsigned char)name[2])) { s = name + 3; - while (isdigit(*s)) + while (isdigit((unsigned char)*s)) ++s; if (*s == NUL) return (1); @@ -1355,7 +1357,7 @@ add_symbol(void) static char * after_blanks(char *s) { - while (*s != '\0' && isspace(*s)) + while (*s != '\0' && isspace((unsigned char)*s)) ++s; return s; } @@ -1424,7 +1426,7 @@ copy_action(void) FREE(d_line); goto loop; } - else if (c == '-' && isdigit(cptr[1])) + else if (c == '-' && isdigit((unsigned char)cptr[1])) { ++cptr; i = -get_number() - n; @@ -1449,7 +1451,7 @@ copy_action(void) cptr += 2; goto loop; } - else if (isdigit(cptr[1])) + else if (isdigit((unsigned char)cptr[1])) { ++cptr; i = get_number(); @@ -1712,8 +1714,8 @@ pack_names(void) if (name_pool == 0) no_space(); - strcpy(name_pool, "$accept"); - strcpy(name_pool + 8, "$end"); + strlcpy(name_pool, "$accept", name_pool_size); + strlcpy(name_pool + 8, "$end", name_pool_size - 8); t = name_pool + 13; for (bp = first_symbol; bp; bp = bp->next) { diff --git a/external/bsd/byacc/dist/skeleton.c b/external/bsd/byacc/dist/skeleton.c index b753688e6525..1baa3bcfff62 100644 --- a/external/bsd/byacc/dist/skeleton.c +++ b/external/bsd/byacc/dist/skeleton.c @@ -1,9 +1,11 @@ -/* $NetBSD: skeleton.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: skeleton.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* Id: skeleton.c,v 1.19 2008/12/24 14:52:28 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: skeleton.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + /* The definition of yysccsid in the banner should be replaced with */ /* a #pragma ident directive if the target C compiler supports */ /* #pragma ident directives. */ @@ -16,7 +18,7 @@ /* the body either are not useful outside of semantic actions or */ /* are conditional. */ -const char *banner[] = +const char * const banner[] = { "#ifndef lint", "static const char yysccsid[] = \"@(#)yaccpar 1.9 (Berkeley) 02/21/93\";", @@ -32,6 +34,7 @@ const char *banner[] = CONCAT1("#define YYPATCH ", YYPATCH), #endif "", + "#define YYLEX yylex()", "#define YYEMPTY (-1)", "#define yyclearin (yychar = YYEMPTY)", "#define yyerrok (yyerrflag = 0)", @@ -55,7 +58,7 @@ const char *banner[] = 0 }; -const char *tables[] = +const char * const tables[] = { "extern short yylhs[];", "extern short yylen[];", @@ -74,7 +77,7 @@ const char *tables[] = 0 }; -const char *header[] = +const char * const header[] = { "#if YYDEBUG", "#include ", @@ -112,7 +115,7 @@ const char *header[] = 0 }; -const char *body[] = +const char * const body[] = { "/* allocate initial stack or double stack size, up to YYMAXDEPTH */", "static int yygrowstack(void)", @@ -303,7 +306,7 @@ const char *body[] = 0 }; -const char *trailer[] = +const char * const trailer[] = { " }", " yyssp -= yym;", @@ -368,7 +371,7 @@ const char *trailer[] = }; void -write_section(const char *section[]) +write_section(const char * const section[]) { int c; int i; diff --git a/external/bsd/byacc/dist/symtab.c b/external/bsd/byacc/dist/symtab.c index 53a96d813d28..b2620541d0d4 100644 --- a/external/bsd/byacc/dist/symtab.c +++ b/external/bsd/byacc/dist/symtab.c @@ -1,9 +1,11 @@ -/* $NetBSD: symtab.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - -/* Id: symtab.c,v 1.7 2008/11/24 21:30:35 tom Exp */ +/* $NetBSD: symtab.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ +/* $Id: symtab.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ #include "defs.h" +#include +__RCSID("$NetBSD: symtab.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + /* TABLE_SIZE is the number of entries in the symbol table. */ /* TABLE_SIZE must be a power of two. */ diff --git a/external/bsd/byacc/dist/test/README b/external/bsd/byacc/dist/test/README index f7bb67cfa458..0737c17a10c8 100644 --- a/external/bsd/byacc/dist/test/README +++ b/external/bsd/byacc/dist/test/README @@ -1,4 +1,4 @@ --- Id: README,v 1.1 2004/03/28 19:10:48 tom Exp +-- $Id: README,v 1.2 2009/10/29 00:56:20 christos Exp $ The files in this directory are input (.y) and output (.output, .tab.c, .tab.h) examples. diff --git a/external/bsd/byacc/dist/test/error.tab.c b/external/bsd/byacc/dist/test/error.tab.c index 081bb377cf17..94a760218f54 100644 --- a/external/bsd/byacc/dist/test/error.tab.c +++ b/external/bsd/byacc/dist/test/error.tab.c @@ -1,7 +1,7 @@ -/* $NetBSD: error.tab.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: error.tab.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ #ifndef lint -static const char yysccsid[] = "@(#)yaccpar 1.9 (Berkeley) 02/21/93"; +/* static const char yysccsid[] = "@(#)yaccpar 1.9 (Berkeley) 02/21/93"; */ +static char rcsid[] = "$NetBSD: error.tab.c,v 1.2 2009/10/29 00:56:20 christos Exp $"; #endif #include diff --git a/external/bsd/byacc/dist/test/error.tab.h b/external/bsd/byacc/dist/test/error.tab.h index 56efb3e4dfd7..27e17fb09aac 100644 --- a/external/bsd/byacc/dist/test/error.tab.h +++ b/external/bsd/byacc/dist/test/error.tab.h @@ -1,2 +1,2 @@ -/* $NetBSD: error.tab.h,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ +/* $NetBSD: error.tab.h,v 1.2 2009/10/29 00:56:20 christos Exp $ */ diff --git a/external/bsd/byacc/dist/test/ftp.tab.c b/external/bsd/byacc/dist/test/ftp.tab.c index 8f8e1b36eb65..11b7ad1712da 100644 --- a/external/bsd/byacc/dist/test/ftp.tab.c +++ b/external/bsd/byacc/dist/test/ftp.tab.c @@ -1,7 +1,7 @@ -/* $NetBSD: ftp.tab.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - +/* $NetBSD: ftp.tab.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ #ifndef lint -static const char yysccsid[] = "@(#)yaccpar 1.9 (Berkeley) 02/21/93"; +/* static const char yysccsid[] = "@(#)yaccpar 1.9 (Berkeley) 02/21/93"; */ +static char rcsid[] = "$NetBSD: ftp.tab.c,v 1.2 2009/10/29 00:56:20 christos Exp $"; #endif #include diff --git a/external/bsd/byacc/dist/test/ftp.tab.h b/external/bsd/byacc/dist/test/ftp.tab.h index b00c6417469b..db864ecd2d9c 100644 --- a/external/bsd/byacc/dist/test/ftp.tab.h +++ b/external/bsd/byacc/dist/test/ftp.tab.h @@ -1,4 +1,4 @@ -/* $NetBSD: ftp.tab.h,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ +/* $NetBSD: ftp.tab.h,v 1.2 2009/10/29 00:56:20 christos Exp $ */ #define A 257 #define B 258 diff --git a/external/bsd/byacc/dist/test/ftp.y b/external/bsd/byacc/dist/test/ftp.y index 719925d6fa69..247c37d99819 100644 --- a/external/bsd/byacc/dist/test/ftp.y +++ b/external/bsd/byacc/dist/test/ftp.y @@ -1,4 +1,4 @@ -/* $NetBSD: ftp.y,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ +/* $NetBSD: ftp.y,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* * Copyright (c) 1985, 1988 Regents of the University of California. @@ -16,7 +16,8 @@ * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. * - * @(#)ftpcmd.y 5.20.1.1 (Berkeley) 3/2/89 + * from: @(#)ftpcmd.y 5.20.1.1 (Berkeley) 3/2/89 + * $NetBSD: ftp.y,v 1.2 2009/10/29 00:56:20 christos Exp $ */ /* @@ -28,6 +29,7 @@ #ifndef lint static char sccsid[] = "@(#)ftpcmd.y 5.20.1.1 (Berkeley) 3/2/89"; +static char rcsid[] = "$NetBSD: ftp.y,v 1.2 2009/10/29 00:56:20 christos Exp $"; #endif /* not lint */ #include @@ -457,8 +459,9 @@ cmd: USER SP username CRLF struct tm *gmtime(); t = gmtime(&stbuf.st_mtime); reply(213, - "19%02d%02d%02d%02d%02d%02d", - t->tm_year, t->tm_mon+1, t->tm_mday, + "%04d%02d%02d%02d%02d%02d", + 1900 + t->tm_year, + t->tm_mon+1, t->tm_mday, t->tm_hour, t->tm_min, t->tm_sec); } } @@ -1148,7 +1151,7 @@ char *filename; (stbuf.st_mode&S_IFMT) != S_IFREG) reply(550, "%s: not a plain file.", filename); else - reply(213, "%lu", stbuf.st_size); + reply(213, "%llu", (long long)stbuf.st_size); break;} case TYPE_A: { FILE *fin; diff --git a/external/bsd/byacc/dist/verbose.c b/external/bsd/byacc/dist/verbose.c index c7d1a16bf888..0a40ca656983 100644 --- a/external/bsd/byacc/dist/verbose.c +++ b/external/bsd/byacc/dist/verbose.c @@ -1,9 +1,11 @@ -/* $NetBSD: verbose.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - -/* Id: verbose.c,v 1.8 2009/10/27 09:12:43 tom Exp */ +/* $NetBSD: verbose.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ +/* Id: verbose.c,v 1.8 2009/10/27 09:12:43 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: verbose.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + static void log_conflicts(void); static void log_unused(void); static void print_actions(int stateno); diff --git a/external/bsd/byacc/dist/warshall.c b/external/bsd/byacc/dist/warshall.c index 2396afb7ddba..55108f8ec75d 100644 --- a/external/bsd/byacc/dist/warshall.c +++ b/external/bsd/byacc/dist/warshall.c @@ -1,9 +1,11 @@ -/* $NetBSD: warshall.c,v 1.1.1.1 2009/10/29 00:46:53 christos Exp $ */ - -/* Id: warshall.c,v 1.6 2008/11/24 21:30:35 tom Exp */ +/* $NetBSD: warshall.c,v 1.2 2009/10/29 00:56:20 christos Exp $ */ +/* Id: warshall.c,v 1.6 2008/11/24 21:30:35 tom Exp */ #include "defs.h" +#include +__RCSID("$NetBSD: warshall.c,v 1.2 2009/10/29 00:56:20 christos Exp $"); + static void transitive_closure(unsigned *R, int n) { diff --git a/external/bsd/byacc/dist/yacc.1 b/external/bsd/byacc/dist/yacc.1 index 65bd64fbc149..5a92646475aa 100644 --- a/external/bsd/byacc/dist/yacc.1 +++ b/external/bsd/byacc/dist/yacc.1 @@ -1,5 +1,4 @@ -.\" $NetBSD: yacc.1,v 1.1.1.1 2009/10/29 00:46:51 christos Exp $ -.\" +.\" $NetBSD: yacc.1,v 1.2 2009/10/29 00:56:20 christos Exp $ .\" Id: yacc.1,v 1.6 2005/05/04 22:11:56 tom Exp .\" .TH YACC 1 "July\ 15,\ 1990"