forked from device-management-toolkit/rpc
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlms.h
More file actions
33 lines (27 loc) · 597 Bytes
/
lms.h
File metadata and controls
33 lines (27 loc) · 597 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/*********************************************************************
* Copyright (c) Intel Corporation 2019 - 2020
* SPDX-License-Identifier: Apache-2.0
**********************************************************************/
#ifndef __LMS_H__
#define __LMS_H__
#include <iostream>
#include <string>
#ifdef _WIN32
#include <winsock2.h>
#else
#include <unistd.h>
typedef int SOCKET;
#define INVALID_SOCKET (SOCKET)(-1)
#endif
#ifdef _WIN32
// Windows
#else
// Linux
static inline int closesocket(int fd)
{
return close(fd);
}
#define SD_BOTH SHUT_RDWR
#endif
SOCKET lms_connect();
#endif