aboutsummaryrefslogtreecommitdiff
path: root/slave.c
diff options
context:
space:
mode:
authorCraig Barnes <craigbarnes@protonmail.com>2024-01-24 23:17:28 +0000
committerDaniel Eklöf <daniel@ekloef.se>2024-02-05 11:09:52 +0000
commite0f3703ae6c4084f9275cfc78d87e5604cc27a10 (patch)
treecdfeebf67f6bb962c5543337b952fe6cf9d40587 /slave.c
parentcsi: simplify handling of Set/Reset Mode (SM/RM) sequences (diff)
util: add streq() function and use in place of strcmp(...) == 0
Diffstat (limited to 'slave.c')
-rw-r--r--slave.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/slave.c b/slave.c
index 47d1c392..bcd864e1 100644
--- a/slave.c
+++ b/slave.c
@@ -21,6 +21,7 @@
#include "macros.h"
#include "terminal.h"
#include "tokenize.h"
+#include "util.h"
#include "xmalloc.h"
extern char **environ;
@@ -121,7 +122,7 @@ is_valid_shell(const char *shell)
if (line[0] == '#')
continue;
- if (strcmp(line, shell) == 0) {
+ if (streq(line, shell)) {
fclose(f);
return true;
}