/*
- * guestInfoInt.h --
+ * getlibInt.h --
*
* Functions used to communicate guest information to the host.
*
*/
-#ifndef GUEST_INFO_INT_H
-#define GUEST_INFO_INT_H
+#ifndef GETLIB_INT_H
+#define GETLIB_INT_H
-
-#include "guestInfo.h"
-#include "guestInfoLib.h"
-#include "guestrpc/nicinfo.h"
+#include "guestInfoInt.h"
#if defined __FreeBSD__ || defined __sun__ || defined __APPLE__
# include <sys/socket.h> // struct sockaddr
Bool GuestInfoGetFqdn(int outBufLen, char fqdn[]);
GuestDiskInfo *GuestInfoGetDiskInfoWiper(void);
Bool GuestInfoGetNicInfo(NicInfoV3 *nicInfo);
-void GuestInfoMemset(void * mem, int value, unsigned int size);
-Bool GuestInfo_PerfMon(struct GuestMemInfo *vmStats);
GuestNicV3 *GuestInfoAddNicEntry(NicInfoV3 *nicInfo, // IN/OUT
const char macAddress[NICINFO_MAC_LEN], // IN
#include <stdlib.h>
#include <string.h>
-#include <glib.h>
#if defined _WIN32
# include <ws2tcpip.h>
#include "vm_assert.h"
#include "debug.h"
-#include "guestInfoInt.h"
+#include "getlibInt.h"
#include "str.h"
#include "util.h"
#include "xdrutil.h"
/* Get partition list. */
if (!WiperPartition_Open(&pl)) {
- Debug("GetDiskInfo: ERROR: could not get partition list\n");
+ g_debug("GetDiskInfo: ERROR: could not get partition list\n");
return FALSE;
}
error = WiperSinglePartition_GetSpace(part, &freeBytes, &totalBytes);
if (strlen(error)) {
- Debug("GetDiskInfo: ERROR: could not get space for partition %s: %s\n",
- part->mountPoint, error);
+ g_debug("GetDiskInfo: ERROR: could not get space for partition %s: %s\n",
+ part->mountPoint, error);
goto out;
}
if (strlen(part->mountPoint) + 1 > partNameSize) {
- Debug("GetDiskInfo: ERROR: Partition name buffer too small\n");
+ g_debug("GetDiskInfo: ERROR: Partition name buffer too small\n");
goto out;
}
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include <glib.h>
#include <fcntl.h>
#ifdef sun
# include <sys/systeminfo.h>
#include "sys/ioctl.h"
#include "vmware.h"
#include "hostinfo.h"
-#include "guestInfoInt.h"
+#include "getlibInt.h"
#include "debug.h"
#include "str.h"
#include "guest_os.h"
{
ASSERT(fqdn);
if (gethostname(fqdn, outBufLen) < 0) {
- Debug("Error, gethostname failed\n");
+ g_debug("Error, gethostname failed\n");
return FALSE;
}
/* Get a handle to read the network interface configuration details. */
if ((intf = intf_open()) == NULL) {
- Debug("GuestInfo: Error, failed NULL result from intf_open()\n");
+ g_debug("Error, failed NULL result from intf_open()\n");
return FALSE;
}
if (intf_loop(intf, ReadInterfaceDetails, nicInfo) < 0) {
intf_close(intf);
- Debug("GuestInfo: Error, negative result from intf_loop\n");
+ g_debug("Error, negative result from intf_loop\n");
return FALSE;
}
union res_sockaddr_union *ns;
ns = Util_SafeCalloc(_res.nscount, sizeof *ns);
if (res_getservers(&_res, ns, _res.nscount) != _res.nscount) {
- Warning("%s: res_getservers failed.\n", __func__);
+ g_warning("%s: res_getservers failed.\n", __func__);
return;
}
for (i = 0; i < _res.nscount; i++) {
Bool ret = TRUE;
if (File_Exists("/proc/net/route") && !RecordRoutingInfoIPv4(nicInfo)) {
- Warning("%s: Unable to collect IPv4 routing table.\n", __func__);
+ g_warning("%s: Unable to collect IPv4 routing table.\n", __func__);
ret = FALSE;
}
if (File_Exists("/proc/net/ipv6_route") && !RecordRoutingInfoIPv6(nicInfo)) {
- Warning("%s: Unable to collect IPv6 routing table.\n", __func__);
+ g_warning("%s: Unable to collect IPv6 routing table.\n", __func__);
ret = FALSE;
}
*
*********************************************************/
+#ifndef _GUESTINFOINT_H_
+#define _GUESTINFOINT_H_
+
/**
* @file guestInfoInt.h
*
* Declares internal functions of the guestInfo plugin.
*/
-#include "guestInfoLib.h"
#define G_LOG_DOMAIN "guestinfo"
+#include <glib.h>
+
+#include "guestInfoLib.h"
extern int guestInfoPollInterval;
Bool
GuestInfo_PerfMon(struct GuestMemInfo *vmStats);
+#endif /* _GUESTINFOINT_H_ */
+