/*********************************************************
- * Copyright (C) 2009-2017 VMware, Inc. All rights reserved.
+ * Copyright (C) 2009-2019 VMware, Inc. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
} HgfsNotifyActivateReason;
/* These are the callbacks that are implemented in hgfsServer.c */
-typedef void (*HgfsNotifyRegisterThreadCb)(struct HgfsSessionInfo *session);
-typedef void (*HgfsNotifyUnregisterThreadCb)(struct HgfsSessionInfo *session);
typedef void (*HgfsNotifyEventReceiveCb)(HgfsSharedFolderHandle sharedFolder,
HgfsSubscriberHandle subscriber,
char *name,
struct HgfsSessionInfo *session);
typedef struct HgfsServerNotifyCallbacks {
- HgfsNotifyRegisterThreadCb registerThread;
- HgfsNotifyUnregisterThreadCb unregisterThread;
HgfsNotifyEventReceiveCb eventReceive;
} HgfsServerNotifyCallbacks;
};
-static void HgfsServerNotifyRegisterThreadCb(struct HgfsSessionInfo *session);
-static void HgfsServerNotifyUnregisterThreadCb(struct HgfsSessionInfo *session);
static void HgfsServerNotifyReceiveEventCb(HgfsSharedFolderHandle sharedFolder,
HgfsSubscriberHandle subscriber,
char* fileName,
* Callback table passed to the directory change notification component.
*/
static const HgfsServerNotifyCallbacks gHgfsServerNotifyCBTable = {
- HgfsServerNotifyRegisterThreadCb,
- HgfsServerNotifyUnregisterThreadCb,
HgfsServerNotifyReceiveEventCb,
};
}
-/*
- *-----------------------------------------------------------------------------
- *
- * HgfsServerNotifyRegisterThreadCb --
- *
- * The callback is invoked by the file system change notification component
- * thread for generating change notification events.
- * This simply calls back to the channel's register thread function, if present,
- * which does the actual work.
- *
- * Results:
- * None.
- *
- * Side effects:
- * None
- *
- *-----------------------------------------------------------------------------
- */
-
-static void
-HgfsServerNotifyRegisterThreadCb(struct HgfsSessionInfo *session) // IN: session info
-{
- HgfsTransportSessionInfo *transportSession;
-
- ASSERT(session);
- transportSession = session->transportSession;
-
- LOG(4, ("%s: Registering thread on session %"FMT64"x\n", __FUNCTION__, session->sessionId));
-
- if (transportSession->channelCbTable->registerThread != NULL) {
- transportSession->channelCbTable->registerThread();
- }
-}
-
-
-/*
- *-----------------------------------------------------------------------------
- *
- * HgfsServerNotifyUnregisterThreadCb --
- *
- * The callback is invoked by the file system change notification component
- * thread for generating change notification events.
- * This simply calls back to the channel's unregister thread function, if present,
- * which does the actual work.
- *
- * Results:
- * None.
- *
- * Side effects:
- * None
- *
- *-----------------------------------------------------------------------------
- */
-
-static void
-HgfsServerNotifyUnregisterThreadCb(struct HgfsSessionInfo *session) // IN: session info
-{
- HgfsTransportSessionInfo *transportSession;
-
- ASSERT(session);
- transportSession = session->transportSession;
-
- LOG(4, ("%s: Unregistering thread on session %"FMT64"x\n", __FUNCTION__, session->sessionId));
-
- if (transportSession->channelCbTable->unregisterThread != NULL) {
- transportSession->channelCbTable->unregisterThread();
- }
-}
-
-
/*
*-----------------------------------------------------------------------------
*
/*********************************************************
- * Copyright (C) 2010-2017 VMware, Inc. All rights reserved.
+ * Copyright (C) 2010-2017,2019 VMware, Inc. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
HGFS_LARGE_PACKET_MAX
};
- connData->channelCbTable.registerThread = NULL;
- connData->channelCbTable.unregisterThread = NULL;
connData->channelCbTable.getWriteVa = NULL;
connData->channelCbTable.getReadVa = NULL;
connData->channelCbTable.putVa = NULL;