From e0f3703ae6c4084f9275cfc78d87e5604cc27a10 Mon Sep 17 00:00:00 2001 From: Craig Barnes Date: Wed, 24 Jan 2024 23:17:28 +0000 Subject: util: add streq() function and use in place of strcmp(...) == 0 --- osc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'osc.c') diff --git a/osc.c b/osc.c index 45d114de..ba08964c 100644 --- a/osc.c +++ b/osc.c @@ -426,7 +426,7 @@ osc_set_pwd(struct terminal *term, char *string) return; } - if (strcmp(scheme, "file") == 0 && hostname_is_localhost(host)) { + if (streq(scheme, "file") && hostname_is_localhost(host)) { LOG_DBG("OSC7: pwd: %s", path); free(term->cwd); term->cwd = path; @@ -483,7 +483,7 @@ osc_uri(struct terminal *term, char *string) const char *value = operator + 1; - if (strcmp(key, "id") == 0) + if (streq(key, "id")) id = sdbm_hash(value); } -- cgit v1.3