提交 9011a494 编写于 作者: E Eric Blake

build: avoid s390 compiler warnings

I noticed these compiler warnings when building for the s390 architecture.

* src/node_device/node_device_udev.c (udevDeviceMonitorStartup):
Mark unused variable.
* src/nodeinfo.c (linuxNodeInfoCPUPopulate): Avoid unused variable.
上级 ddf2dfa1
/*
* node_device_udev.c: node device enumeration - libudev implementation
*
* Copyright (C) 2009-2011 Red Hat, Inc.
* Copyright (C) 2009-2012 Red Hat, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
......@@ -1604,7 +1604,7 @@ out:
return ret;
}
static int udevDeviceMonitorStartup(int privileged)
static int udevDeviceMonitorStartup(int privileged ATTRIBUTE_UNUSED)
{
udevPrivate *priv = NULL;
struct udev *udev = NULL;
......
......@@ -231,10 +231,10 @@ int linuxNodeInfoCPUPopulate(FILE *cpuinfo,
/* NOTE: hyperthreads are ignored here; they are parsed out of /sys */
while (fgets(line, sizeof(line), cpuinfo) != NULL) {
char *buf = line;
# if defined(__x86_64__) || \
defined(__amd64__) || \
defined(__i386__)
char *buf = line;
if (STRPREFIX(buf, "cpu MHz")) {
char *p;
unsigned int ui;
......@@ -253,6 +253,7 @@ int linuxNodeInfoCPUPopulate(FILE *cpuinfo,
}
# elif defined(__powerpc__) || \
defined(__powerpc64__)
char *buf = line;
if (STRPREFIX(buf, "clock")) {
char *p;
unsigned int ui;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册