From a0c98b64708f58716a35ec131f91e990346790eb Mon Sep 17 00:00:00 2001 From: Ben Kibbey Date: Sat, 25 Apr 2009 16:12:44 -0400 Subject: [PATCH] Use g_ascii_strcasecmp() and not g_strcmp0(). g_strcmp0() was added in later versions of libglib and really isn't needed. --- src/commands.c | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/src/commands.c b/src/commands.c index 44da27ad..966385bd 100644 --- a/src/commands.c +++ b/src/commands.c @@ -981,7 +981,7 @@ write_file: tmp[0] = 0; if (filename) { - if (!client && !g_strcmp0(filename, "-")) { + if (!client && !g_ascii_strcasecmp(filename, "-")) { crypto->fh->fd = STDOUT_FILENO; goto do_write_file; } @@ -3028,30 +3028,30 @@ int command_startup(assuan_context_t ctx, const char *name) struct client_s *cl = assuan_get_pointer(ctx); gpg_error_t rc; - if (!g_strcmp0(name, "ISCACHED") || - !g_strcmp0(name, "CLEARCACHE") || - !g_strcmp0(name, "CACHETIMEOUT") || - !g_strcmp0(name, "GETCONFIG") || - !g_strcmp0(name, "GETPID") || - !g_strcmp0(name, "VERSION") || - !g_strcmp0(name, "SET") || - !g_strcmp0(name, "BYE") || - !g_strcmp0(name, "NOP") || - !g_strcmp0(name, "CANCEL") || - !g_strcmp0(name, "RESET") || - !g_strcmp0(name, "END") || - !g_strcmp0(name, "HELP") || - !g_strcmp0(name, "OPTION") || - !g_strcmp0(name, "INPUT") || - !g_strcmp0(name, "OUTPUT") || - !g_strcmp0(name, "UNSET")) + if (!g_ascii_strcasecmp(name, "ISCACHED") || + !g_ascii_strcasecmp(name, "CLEARCACHE") || + !g_ascii_strcasecmp(name, "CACHETIMEOUT") || + !g_ascii_strcasecmp(name, "GETCONFIG") || + !g_ascii_strcasecmp(name, "GETPID") || + !g_ascii_strcasecmp(name, "VERSION") || + !g_ascii_strcasecmp(name, "SET") || + !g_ascii_strcasecmp(name, "BYE") || + !g_ascii_strcasecmp(name, "NOP") || + !g_ascii_strcasecmp(name, "CANCEL") || + !g_ascii_strcasecmp(name, "RESET") || + !g_ascii_strcasecmp(name, "END") || + !g_ascii_strcasecmp(name, "HELP") || + !g_ascii_strcasecmp(name, "OPTION") || + !g_ascii_strcasecmp(name, "INPUT") || + !g_ascii_strcasecmp(name, "OUTPUT") || + !g_ascii_strcasecmp(name, "UNSET")) return 0; rc = file_modified(cl); if (rc) { if ((rc == EPWMD_NO_FILE || rc == EPWMD_FILE_MODIFIED) && - !g_strcmp0(name, "OPEN")) + !g_ascii_strcasecmp(name, "OPEN")) rc = 0; } -- 2.11.4.GIT