diff options
author | 2016-04-09 20:28:27 +0000 | |
---|---|---|
committer | 2016-04-09 20:28:27 +0000 | |
commit | 9e107a6ebe8c98a63a93d17c26c6649c88f2016c (patch) | |
tree | 5742d3611526a8cfa471bfa1f33a0009744d1611 | |
parent | Delete 26 wrapper macros and two wrapper functions that are no (diff) | |
download | wireguard-openbsd-9e107a6ebe8c98a63a93d17c26c6649c88f2016c.tar.xz wireguard-openbsd-9e107a6ebe8c98a63a93d17c26c6649c88f2016c.zip |
For pointers, use NULL rather than 0; no functional change;
from Pedro Giffuni via Christos Zoulas.
-rw-r--r-- | lib/libedit/filecomplete.c | 6 | ||||
-rw-r--r-- | lib/libedit/vi.c | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/lib/libedit/filecomplete.c b/lib/libedit/filecomplete.c index 82f69099efd..bf283d8676f 100644 --- a/lib/libedit/filecomplete.c +++ b/lib/libedit/filecomplete.c @@ -1,4 +1,4 @@ -/* $OpenBSD: filecomplete.c,v 1.9 2016/03/20 23:48:27 schwarze Exp $ */ +/* $OpenBSD: filecomplete.c,v 1.10 2016/04/09 20:28:27 schwarze Exp $ */ /* $NetBSD: filecomplete.c,v 1.22 2010/12/02 04:42:46 dholland Exp $ */ /*- @@ -429,7 +429,7 @@ fn_complete(EditLine *el, /* these can be used by function called in completion_matches() */ /* or (*attempted_completion_function)() */ - if (point != 0) + if (point != NULL) *point = (int)(li->cursor - li->buffer); if (end != NULL) *end = (int)(li->lastchar - li->buffer); @@ -440,7 +440,7 @@ fn_complete(EditLine *el, ct_encode_string(temp, &el->el_scratch), (int)(cur_off - len), cur_off); } else - matches = 0; + matches = NULL; if (!attempted_completion_function || (over != NULL && !*over && !matches)) matches = completion_matches( diff --git a/lib/libedit/vi.c b/lib/libedit/vi.c index c3f60855f34..5cf96a3de94 100644 --- a/lib/libedit/vi.c +++ b/lib/libedit/vi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vi.c,v 1.20 2016/04/09 20:15:26 schwarze Exp $ */ +/* $OpenBSD: vi.c,v 1.21 2016/04/09 20:28:27 schwarze Exp $ */ /* $NetBSD: vi.c,v 1.33 2011/02/17 16:44:48 joerg Exp $ */ /*- @@ -1099,7 +1099,7 @@ vi_history_word(EditLine *el, wint_t c __attribute__((__unused__))) if (wp == NULL) return CC_ERROR; - wep = wsp = 0; + wep = wsp = NULL; do { while (iswspace(*wp)) wp++; @@ -1112,7 +1112,7 @@ vi_history_word(EditLine *el, wint_t c __attribute__((__unused__))) } while ((!el->el_state.doingarg || --el->el_state.argument > 0) && *wp != 0); - if (wsp == 0 || (el->el_state.doingarg && el->el_state.argument != 0)) + if (wsp == NULL || (el->el_state.doingarg && el->el_state.argument != 0)) return CC_ERROR; cv_undo(el); |