There is no real need for including tools/xenstore/utils.h from
libxenstore, as only streq() and ARRAY_SIZE() are obtained via that
header.
streq() is just !strcmp(), and ARRAY_SIZE() is brought in via
xen-tools/common-macros.h.
Signed-off-by: Juergen Gross <jgross@suse.com>
Acked-by: Julien Grall <jgrall@amazon.com>
#include <signal.h>
#include <stdint.h>
#include <errno.h>
+#include <xen-tools/common-macros.h>
#include "xenstore.h"
#include "xs_lib.h"
-#include "utils.h"
#include <xentoolcore_internal.h>
#include <xen_list.h>
{
unsigned int i;
- for (i = 0; !streq(errorstring, xsd_errors[i].errstring); i++)
+ for (i = 0; strcmp(errorstring, xsd_errors[i].errstring); i++)
if (i == ARRAY_SIZE(xsd_errors) - 1)
return EINVAL;
return xsd_errors[i].errnum;