wscons: Fix STRLEN

This commit is contained in:
Kenny Levinsen 2022-03-30 00:39:35 +02:00
parent 2842f0e2b1
commit 6888653a8d

View file

@ -12,9 +12,9 @@
#if defined(__NetBSD__) #if defined(__NetBSD__)
int path_is_wscons(const char *path) { int path_is_wscons(const char *path) {
const char *wskbd = "/dev/wskbd"; static const char wskbd[] = "/dev/wskbd";
const char *wsmouse = "/dev/wsmouse"; static const char wsmouse[] = "/dev/wsmouse";
const char *wsmux = "/dev/wsmux"; static const char wsmux[] = "/dev/wsmux";
return strncmp(path, wskbd, STRLEN(wskbd)) == 0 || return strncmp(path, wskbd, STRLEN(wskbd)) == 0 ||
strncmp(path, wsmouse, STRLEN(wsmouse)) == 0 || strncmp(path, wsmouse, STRLEN(wsmouse)) == 0 ||
strncmp(path, wsmux, STRLEN(wsmouse)) == 0; strncmp(path, wsmux, STRLEN(wsmouse)) == 0;