qemu-option: Rename find_list() to qemu_find_opts() & external linkage
authorMarkus Armbruster <armbru@redhat.com>
Wed, 10 Feb 2010 19:09:14 +0000 (20:09 +0100)
committerMarkus Armbruster <armbru@redhat.com>
Tue, 16 Mar 2010 16:45:35 +0000 (17:45 +0100)
Next commit wants to use it.

qemu-config.c
qemu-config.h

index a2e0193..150157c 100644 (file)
@@ -309,7 +309,7 @@ static QemuOptsList *lists[] = {
     NULL,
 };
 
-static QemuOptsList *find_list(const char *group)
+QemuOptsList *qemu_find_opts(const char *group)
 {
     int i;
 
@@ -336,7 +336,7 @@ int qemu_set_option(const char *str)
         return -1;
     }
 
-    list = find_list(group);
+    list = qemu_find_opts(group);
     if (list == NULL) {
         return -1;
     }
@@ -451,7 +451,7 @@ int qemu_config_parse(FILE *fp, const char *fname)
         }
         if (sscanf(line, "[%63s \"%63[^\"]\"]", group, id) == 2) {
             /* group with id */
-            list = find_list(group);
+            list = qemu_find_opts(group);
             if (list == NULL)
                 goto out;
             opts = qemu_opts_create(list, id, 1);
@@ -459,7 +459,7 @@ int qemu_config_parse(FILE *fp, const char *fname)
         }
         if (sscanf(line, "[%63[^]]]", group) == 1) {
             /* group without id */
-            list = find_list(group);
+            list = qemu_find_opts(group);
             if (list == NULL)
                 goto out;
             opts = qemu_opts_create(list, NULL, 0);
index c507687..f217c58 100644 (file)
@@ -11,6 +11,7 @@ extern QemuOptsList qemu_global_opts;
 extern QemuOptsList qemu_mon_opts;
 extern QemuOptsList qemu_cpudef_opts;
 
+QemuOptsList *qemu_find_opts(const char *group);
 int qemu_set_option(const char *str);
 int qemu_global_option(const char *str);
 void qemu_add_globals(void);