From 2aa53cbdd1bc43d5b22a762c2116fe490afc62f7 Mon Sep 17 00:00:00 2001 From: Jay Sorg Date: Thu, 2 Aug 2012 16:22:01 -0700 Subject: xrdpapi: add cplusplus for header --- xrdpapi/xrdpapi.c | 1 + xrdpapi/xrdpapi.h | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/xrdpapi/xrdpapi.c b/xrdpapi/xrdpapi.c index 3190cd39..8223c3b2 100644 --- a/xrdpapi/xrdpapi.c +++ b/xrdpapi/xrdpapi.c @@ -151,6 +151,7 @@ send_init(struct wts_obj* wts) char initmsg[64]; memset(initmsg, 0, 64); + strncpy(initmsg, wts->name, 8); if (!can_send(wts->fd, 500)) { return 1; diff --git a/xrdpapi/xrdpapi.h b/xrdpapi/xrdpapi.h index cb451559..c39c4f1b 100644 --- a/xrdpapi/xrdpapi.h +++ b/xrdpapi/xrdpapi.h @@ -24,6 +24,10 @@ #if !defined(XRDPAPI_H_) #define XRDPAPI_H_ +#ifdef __cplusplus +extern "C" { +#endif + #define WTS_CURRENT_SERVER_HANDLE 0 #define WTS_CURRENT_SESSION 0xffffffff @@ -59,4 +63,8 @@ WTSVirtualChannelQuery(void* hChannelHandle, WTS_VIRTUAL_CLASS WtsVirtualClass, void WTSFreeMemory(void* pMemory); +#ifdef __cplusplus +} +#endif + #endif /* XRDPAPI_H_ */ -- cgit v1.2.1