dhcpserver: support cplusplus

Closes https://github.com/espressif/esp-idf/issues/7494

Merges https://github.com/espressif/esp-idf/pull/7526
This commit is contained in:
yuanjm 2021-08-31 16:26:55 +08:00 committed by bot
parent f6f417ceee
commit f570b33b66
2 changed files with 14 additions and 0 deletions

View File

@ -17,6 +17,10 @@
#include "sdkconfig.h"
#include "lwip/ip_addr.h"
#ifdef __cplusplus
extern "C" {
#endif
typedef struct dhcps_state{
s16_t state;
} dhcps_state;
@ -91,5 +95,8 @@ void dhcps_dns_setserver(const ip_addr_t *dnsserver);
ip4_addr_t dhcps_dns_getserver(void);
void dhcps_set_new_lease_cb(dhcps_cb_t cb);
#ifdef __cplusplus
}
#endif
#endif /* __DHCPS_H__ */

View File

@ -13,6 +13,9 @@
// limitations under the License.
#pragma once
#ifdef __cplusplus
extern "C" {
#endif
/** DHCP Options
This macros are not part of the public dhcpserver.h interface.
@ -132,3 +135,7 @@ typedef enum
DOMAIN_SEARCH = 119,
CLASSLESS_ROUTE = 121,
} dhcp_msg_option;
#ifdef __cplusplus
}
#endif