diff options
author | okan | 2020-02-27 14:56:39 +0000 |
---|---|---|
committer | Wynn Wolf Arbor | 2020-03-18 14:30:58 +0100 |
commit | d8f3547b8f545b439d9df7b41cfe872ce6c8f42d (patch) | |
tree | 1be865226e709457b823835f42a3ed338801f74a /search.c | |
parent | a4006dcef17be430ad3cc2c2a63ea1de75a20d62 (diff) | |
download | cwm-d8f3547b8f545b439d9df7b41cfe872ce6c8f42d.tar.gz |
Unrelated style fixes, consistency changes and sorting, appropriate dosage/removal of wrappers, simplification of name queue, client cycle joins other kb/mb bound functions.
Diffstat (limited to '')
-rw-r--r-- | search.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -15,7 +15,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * - * $OpenBSD: search.c,v 1.69 2018/02/02 13:27:25 okan Exp $ + * $OpenBSD: search.c,v 1.70 2020/02/27 14:56:39 okan Exp $ */ #include <sys/types.h> @@ -46,13 +46,13 @@ match_substr(char *sub, char *str, int zeroidx) unsigned int n, flen; if (sub == NULL || str == NULL) - return(0); + return 0; len = strlen(str); sublen = strlen(sub); if (sublen > len) - return(0); + return 0; if (zeroidx) flen = 0; @@ -61,9 +61,9 @@ match_substr(char *sub, char *str, int zeroidx) for (n = 0; n <= flen; n++) if (strncasecmp(sub, str + n, sublen) == 0) - return(1); + return 1; - return(0); + return 0; } void @@ -94,7 +94,7 @@ search_match_client(struct menu_q *menuq, struct menu_q *resultq, char *search) } /* Match on window resource class. */ - if ((tier < 0) && match_substr(search, cc->ch.res_class, 0)) + if ((tier < 0) && match_substr(search, cc->res_class, 0)) tier = 2; if (tier < 0) |