Don't use loops with empty body.

This commit is contained in:
joerg 2012-02-25 00:13:00 +00:00
parent 268a453af7
commit 8c3e60d97f
2 changed files with 5 additions and 4 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: ex_tag.c,v 1.10 2011/08/17 12:56:55 christos Exp $ */
/* $NetBSD: ex_tag.c,v 1.11 2012/02/25 00:13:00 joerg Exp $ */
/*-
* Copyright (c) 1992, 1993, 1994
@ -1411,7 +1411,7 @@ ctag_file(SCR *sp, TAGF *tfp, char *name, char **dirp, size_t *dlenp)
#define GREATER 1
#define LESS (-1)
#define SKIP_PAST_NEWLINE(p, back) while (p < back && *p++ != '\n');
#define SKIP_PAST_NEWLINE(p, back) while (p < back && *p++ != '\n') continue;
static char *
binary_search(register char *string, register char *front, register char *back)

View File

@ -1,4 +1,4 @@
/* $NetBSD: vs_msg.c,v 1.4 2010/05/13 17:52:11 tnozaki Exp $ */
/* $NetBSD: vs_msg.c,v 1.5 2012/02/25 00:13:00 joerg Exp $ */
/*-
* Copyright (c) 1993, 1994
@ -897,7 +897,8 @@ vs_msgsave(SCR *sp, mtype_t mt, char *p, size_t len)
if ((mp_c = gp->msgq.lh_first) == NULL) {
LIST_INSERT_HEAD(&gp->msgq, mp_n, q);
} else {
for (; mp_c->q.le_next != NULL; mp_c = mp_c->q.le_next);
while (mp_c->q.le_next != NULL)
mp_c = mp_c->q.le_next;
LIST_INSERT_AFTER(mp_c, mp_n, q);
}
return;