/*
* High level api to nfs filesystems
*/
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#ifdef AROS
+#include "aros_compat.h"
+#endif
+
#ifdef WIN32
#include "win32_compat.h"
-#define DllExport
#else
#include <strings.h>
-#include <unistd.h>
-#include <sys/statvfs.h>
-#include <poll.h>
-#include <sys/ioctl.h>
#include <netdb.h>
#include <sys/socket.h>
#include <net/if.h>
+#endif /*WIN32*/
+
+#ifdef ANDROID
+#define statvfs statfs
#endif
-#ifdef HAVE_CONFIG_H
-#include "config.h"
+#ifdef HAVE_SYS_VFS_H
+#include <sys/vfs.h>
+#endif
+
+#ifdef HAVE_SYS_STATVFS_H
+#include <sys/statvfs.h>
+#endif
+
+#ifdef HAVE_SYS_IOCTL_H
+#include <sys/ioctl.h>
+#endif
+
+#ifdef HAVE_POLL_H
+#include <poll.h>
+#endif
+
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
#endif
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <assert.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
+#include <netinet/in.h>
#include <errno.h>
#ifdef HAVE_SYS_SOCKIO_H
{
struct pollfd pfd;
+ assert(rpc->magic == RPC_CONTEXT_MAGIC);
+
while (!cb_data->is_finished) {
pfd.fd = rpc_get_fd(rpc);
struct sync_cb_data cb_data;
struct rpc_context *rpc = nfs_get_rpc_context(nfs);
+ assert(rpc->magic == RPC_CONTEXT_MAGIC);
+
cb_data.is_finished = 0;
if (nfs_mount_async(nfs, server, export, mount_cb, &cb_data) != 0) {
struct sync_cb_data *cb_data = private_data;
exports export;
+ assert(mount_context->magic == RPC_CONTEXT_MAGIC);
+
cb_data->is_finished = 1;
cb_data->status = status;
cb_data->return_data = NULL;
char hostdd[16];
struct nfs_server_list *srvr;
+ assert(rpc->magic == RPC_CONTEXT_MAGIC);
+
if (status == RPC_STATUS_CANCEL) {
return;
}
{
int i=0;
+ assert(rpc->magic == RPC_CONTEXT_MAGIC);
+
for(i = 0; i < numIfs; i++)
{
SOCKADDR *pAddress;
{
char *ptr;
+ assert(rpc->magic == RPC_CONTEXT_MAGIC);
+
for (ptr =(char *)(ifc->ifc_buf); ptr < (char *)(ifc->ifc_buf) + ifc->ifc_len; ) {
struct ifreq *ifr;
char bcdd[16];