static subnet_t ipv4, ipv6;
void ifconfig_address(FILE *out, const char *value) {
- subnet_t address = {};
+ subnet_t address = {NULL};
char address_str[MAXNETSTR];
if(!str2net(&address, value) || !net2str(address_str, sizeof(address_str), &address)) {
}
void ifconfig_route(FILE *out, const char *value) {
- subnet_t subnet = {}, gateway = {};
+ subnet_t subnet = {NULL}, gateway = {NULL};
char subnet_str[MAXNETSTR] = "", gateway_str[MAXNETSTR] = "";
char *sep = strchr(value, ' ');
logger(DEBUG_ALWAYS, LOG_INFO, "%s is a %s", device, device_info);
if(ifr.ifr_flags & IFF_TAP) {
- struct ifreq ifr_mac = {};
+ struct ifreq ifr_mac = {{{0}}};
if(!ioctl(device_fd, SIOCGIFHWADDR, &ifr_mac)) {
memcpy(mymac.x, ifr_mac.ifr_hwaddr.sa_data, ETH_ALEN);
if(relay_supported) {
if(direct) {
/* Inform the recipient that this packet was sent directly. */
- node_id_t nullid = {};
+ node_id_t nullid = {{0}};
memcpy(buf_ptr, &nullid, sizeof(nullid));
buf_ptr += sizeof(nullid);
} else {
static void handle_incoming_vpn_packet(listen_socket_t *ls, vpn_packet_t *pkt, sockaddr_t *addr) {
char *hostname;
- node_id_t nullid = {};
+ node_id_t nullid = {{0}};
node_t *from, *to;
bool direct = false;