diff options
-rw-r--r-- | chars.c | 4 | ||||
-rw-r--r-- | html.c | 4 | ||||
-rw-r--r-- | main.c | 15 | ||||
-rw-r--r-- | mandoc.c | 8 | ||||
-rw-r--r-- | mdoc_html.c | 2 | ||||
-rw-r--r-- | roff.c | 2 | ||||
-rw-r--r-- | term.c | 4 | ||||
-rw-r--r-- | term_ascii.c | 1 | ||||
-rw-r--r-- | term_ps.c | 5 |
9 files changed, 23 insertions, 22 deletions
@@ -94,13 +94,13 @@ chars_init(enum chars type) tab = malloc(sizeof(struct tbl)); if (NULL == tab) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } htab = calloc(PRINT_HI - PRINT_LO + 1, sizeof(struct ln **)); if (NULL == htab) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } for (i = 0; i < LINES_MAX; i++) { @@ -116,7 +116,7 @@ ml_alloc(char *outopts, enum htmltype type) h = calloc(1, sizeof(struct html)); if (NULL == h) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } h->type = type; @@ -398,7 +398,7 @@ print_otag(struct html *h, enum htmltag tag, t = malloc(sizeof(struct tag)); if (NULL == t) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } t->tag = tag; t->next = h->tags.head; @@ -231,7 +231,7 @@ main(int argc, char *argv[]) switch (c) { case ('m'): if ( ! moptions(&curp.inttype, optarg)) - return(MANDOCLEVEL_BADARG); + return((int)MANDOCLEVEL_BADARG); break; case ('O'): (void)strlcat(curp.outopts, optarg, BUFSIZ); @@ -239,11 +239,11 @@ main(int argc, char *argv[]) break; case ('T'): if ( ! toptions(&curp, optarg)) - return(MANDOCLEVEL_BADARG); + return((int)MANDOCLEVEL_BADARG); break; case ('W'): if ( ! woptions(&curp, optarg)) - return(MANDOCLEVEL_BADARG); + return((int)MANDOCLEVEL_BADARG); break; case ('V'): version(); @@ -279,7 +279,7 @@ main(int argc, char *argv[]) if (curp.roff) roff_free(curp.roff); - return(exit_status); + return((int)exit_status); } @@ -288,7 +288,7 @@ version(void) { (void)printf("%s %s\n", progname, VERSION); - exit(MANDOCLEVEL_OK); + exit((int)MANDOCLEVEL_OK); } @@ -299,7 +299,7 @@ usage(void) (void)fprintf(stderr, "usage: %s [-V] [-foption] " "[-mformat] [-Ooption] [-Toutput] " "[-Werr] [file...]\n", progname); - exit(MANDOCLEVEL_BADARG); + exit((int)MANDOCLEVEL_BADARG); } @@ -329,7 +329,7 @@ resize_buf(struct buf *buf, size_t initial) buf->buf = realloc(buf->buf, buf->sz); if (NULL == buf->buf) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } } @@ -809,6 +809,7 @@ mmsg(enum mandocerr t, void *arg, int ln, int col, const char *msg) level = MANDOCLEVEL_FATAL; while (t < mandoclimits[level]) + /* LINTED */ level--; cp = (struct curparse *)arg; @@ -233,7 +233,7 @@ mandoc_calloc(size_t num, size_t size) ptr = calloc(num, size); if (NULL == ptr) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } return(ptr); @@ -248,7 +248,7 @@ mandoc_malloc(size_t size) ptr = malloc(size); if (NULL == ptr) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } return(ptr); @@ -262,7 +262,7 @@ mandoc_realloc(void *ptr, size_t size) ptr = realloc(ptr, size); if (NULL == ptr) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } return(ptr); @@ -277,7 +277,7 @@ mandoc_strdup(const char *ptr) p = strdup(ptr); if (NULL == p) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } return(p); diff --git a/mdoc_html.c b/mdoc_html.c index 93807dd5..32334432 100644 --- a/mdoc_html.c +++ b/mdoc_html.c @@ -1183,7 +1183,7 @@ mdoc_bl_pre(MDOC_ARGS) ord = malloc(sizeof(struct ord)); if (NULL == ord) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } ord->cookie = n; ord->pos = 1; @@ -749,7 +749,6 @@ roff_cond_sub(ROFF_ARGS) { enum rofft t; enum roffrule rr; - struct roffnode *l; ppos = pos; rr = r->last->rule; @@ -759,7 +758,6 @@ roff_cond_sub(ROFF_ARGS) * continue. */ - l = r->last; roffnode_cleanscope(r); if (ROFF_MAX == (t = roff_parse(*bufp, &pos))) { @@ -83,7 +83,7 @@ term_alloc(enum termenc enc) p = calloc(1, sizeof(struct termp)); if (NULL == p) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } p->enc = enc; @@ -576,7 +576,7 @@ adjbuf(struct termp *p, size_t sz) p->buf = realloc(p->buf, p->maxcols); if (NULL == p->buf) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } } diff --git a/term_ascii.c b/term_ascii.c index 06d0132b..8be733a6 100644 --- a/term_ascii.c +++ b/term_ascii.c @@ -104,6 +104,7 @@ static void ascii_letter(struct termp *p, char c) { + /* LINTED */ putchar(c); } @@ -372,7 +372,7 @@ ps_growbuf(struct termp *p, size_t sz) if (NULL == p->engine.ps.psmarg) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } } @@ -583,6 +583,7 @@ ps_putchar(struct termp *p, char c) /* See ps_printf(). */ if ( ! (PS_MARGINS & p->engine.ps.flags)) { + /* LINTED */ putchar(c); p->engine.ps.pdfbytes++; return; @@ -609,7 +610,7 @@ pdf_obj(struct termp *p, size_t obj) p->engine.ps.pdfobjsz * sizeof(size_t)); if (NULL == p->engine.ps.pdfobjs) { perror(NULL); - exit(MANDOCLEVEL_SYSERR); + exit((int)MANDOCLEVEL_SYSERR); } } |