2 * Dealing with identifiers
4 * Copyright (C) 2014 Red Hat, Inc.
7 * Markus Armbruster <armbru@redhat.com>,
9 * This work is licensed under the terms of the GNU LGPL, version 2.1
10 * or later. See the COPYING.LIB file in the top-level directory.
13 #include "qemu-common.h"
15 bool id_wellformed(const char *id
)
19 if (!qemu_isalpha(id
[0])) {
22 for (i
= 1; id
[i
]; i
++) {
23 if (!qemu_isalnum(id
[i
]) && !strchr("-._", id
[i
])) {