Blob Blame Raw
From 1d20e66fdee76ee9a7cab19de50a138588f0c8c8 Mon Sep 17 00:00:00 2001
Message-Id: <1d20e66fdee76ee9a7cab19de50a138588f0c8c8.1383564115.git.minovotn@redhat.com>
In-Reply-To: <5575e0aec51f40ebec46e98ec085cda053283aba.1383564115.git.minovotn@redhat.com>
References: <5575e0aec51f40ebec46e98ec085cda053283aba.1383564115.git.minovotn@redhat.com>
From: Markus Armbruster <armbru@redhat.com>
Date: Fri, 27 Sep 2013 13:31:12 +0200
Subject: [PATCH 02/14] qemu-option: check_params() is now unused, drop it

RH-Author: Markus Armbruster <armbru@redhat.com>
Message-id: <1380288680-26645-3-git-send-email-armbru@redhat.com>
Patchwork-id: 54559
O-Subject: [PATCH 7.0 qemu-kvm 02/10] qemu-option: check_params() is now unused, drop it
Bugzilla: 997817
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
RH-Acked-by: Laszlo Ersek <lersek@redhat.com>
RH-Acked-by: Luiz Capitulino <lcapitulino@redhat.com>

From: Markus Armbruster <armbru@redhat.com>

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>
Message-id: 1371208516-7857-3-git-send-email-armbru@redhat.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
(cherry picked from commit a86b35f992f107323e432c0a96107e11e1b699ad)
---
 include/qemu/option.h |  2 --
 util/qemu-option.c    | 30 ------------------------------
 2 files changed, 32 deletions(-)

Signed-off-by: Michal Novotny <minovotn@redhat.com>
---
 include/qemu/option.h |  2 --
 util/qemu-option.c    | 30 ------------------------------
 2 files changed, 32 deletions(-)

diff --git a/include/qemu/option.h b/include/qemu/option.h
index 9db74fb..13f5e72 100644
--- a/include/qemu/option.h
+++ b/include/qemu/option.h
@@ -55,8 +55,6 @@ int get_next_param_value(char *buf, int buf_size,
                          const char *tag, const char **pstr);
 int get_param_value(char *buf, int buf_size,
                     const char *tag, const char *str);
-int check_params(char *buf, int buf_size,
-                 const char * const *params, const char *str);
 
 
 /*
diff --git a/util/qemu-option.c b/util/qemu-option.c
index 37e7640..5d686c8 100644
--- a/util/qemu-option.c
+++ b/util/qemu-option.c
@@ -123,36 +123,6 @@ int get_param_value(char *buf, int buf_size,
     return get_next_param_value(buf, buf_size, tag, &str);
 }
 
-int check_params(char *buf, int buf_size,
-                 const char * const *params, const char *str)
-{
-    const char *p;
-    int i;
-
-    p = str;
-    while (*p != '\0') {
-        p = get_opt_name(buf, buf_size, p, '=');
-        if (*p != '=') {
-            return -1;
-        }
-        p++;
-        for (i = 0; params[i] != NULL; i++) {
-            if (!strcmp(params[i], buf)) {
-                break;
-            }
-        }
-        if (params[i] == NULL) {
-            return -1;
-        }
-        p = get_opt_value(NULL, 0, p);
-        if (*p != ',') {
-            break;
-        }
-        p++;
-    }
-    return 0;
-}
-
 /*
  * Searches an option list for an option with the given name
  */
-- 
1.7.11.7