Deleted Added
full compact
advcap.c (71333) advcap.c (78064)
1/* $FreeBSD: head/usr.sbin/rtadvd/advcap.c 71333 2001-01-21 15:25:46Z itojun $ */
2/* $KAME: advcap.c,v 1.3 2000/05/16 13:34:13 itojun Exp $ */
1/* $FreeBSD: head/usr.sbin/rtadvd/advcap.c 78064 2001-06-11 12:39:29Z ume $ */
2/* $KAME: advcap.c,v 1.5 2001/02/01 09:12:08 jinmei Exp $ */
3
4/*
5 * Copyright (c) 1983 The Regents of the University of California.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions
10 * are met:

--- 80 unchanged lines hidden (view full) ---

91
92extern char *conffile;
93
94int tgetent __P((char *, char *));
95int getent __P((char *, char *, char *));
96int tnchktc __P((void));
97int tnamatch __P((char *));
98static char *tskip __P((char *));
3
4/*
5 * Copyright (c) 1983 The Regents of the University of California.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions
10 * are met:

--- 80 unchanged lines hidden (view full) ---

91
92extern char *conffile;
93
94int tgetent __P((char *, char *));
95int getent __P((char *, char *, char *));
96int tnchktc __P((void));
97int tnamatch __P((char *));
98static char *tskip __P((char *));
99int tgetnum __P((char *));
99long long tgetnum __P((char *));
100int tgetflag __P((char *));
101char *tgetstr __P((char *, char **));
102static char *tdecode __P((char *, char **));
103
104/*
105 * Get an entry for terminal name in buffer bp,
106 * from the termcap file. Parse is very rudimentary;
107 * we just notice escaped newlines.

--- 194 unchanged lines hidden (view full) ---

302/*
303 * Return the (numeric) option id.
304 * Numeric options look like
305 * li#80
306 * i.e. the option string is separated from the numeric value by
307 * a # character. If the option is not found we return -1.
308 * Note that we handle octal numbers beginning with 0.
309 */
100int tgetflag __P((char *));
101char *tgetstr __P((char *, char **));
102static char *tdecode __P((char *, char **));
103
104/*
105 * Get an entry for terminal name in buffer bp,
106 * from the termcap file. Parse is very rudimentary;
107 * we just notice escaped newlines.

--- 194 unchanged lines hidden (view full) ---

302/*
303 * Return the (numeric) option id.
304 * Numeric options look like
305 * li#80
306 * i.e. the option string is separated from the numeric value by
307 * a # character. If the option is not found we return -1.
308 * Note that we handle octal numbers beginning with 0.
309 */
310int
310long long
311tgetnum(id)
312 char *id;
313{
311tgetnum(id)
312 char *id;
313{
314 register long int i;
314 register long long i;
315 register int base;
316 register char *bp = tbuf;
317
318 for (;;) {
319 bp = tskip(bp);
320 if (*bp == 0)
321 return (-1);
322 if (strncmp(bp, id, strlen(id)) != 0)

--- 132 unchanged lines hidden ---
315 register int base;
316 register char *bp = tbuf;
317
318 for (;;) {
319 bp = tskip(bp);
320 if (*bp == 0)
321 return (-1);
322 if (strncmp(bp, id, strlen(id)) != 0)

--- 132 unchanged lines hidden ---