windows/net: Definition for IFNAMSIZ.
authorGurucharan Shetty <gshetty@nicira.com>
Wed, 12 Mar 2014 16:51:13 +0000 (09:51 -0700)
committerGurucharan Shetty <gshetty@nicira.com>
Thu, 13 Mar 2014 21:23:30 +0000 (14:23 -0700)
Signed-off-by: Gurucharan Shetty <gshetty@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
include/windows/net/if.h
lib/netdev-vport.h

index e69de29..893ffe4 100644 (file)
@@ -0,0 +1,24 @@
+/*
+ * Copyright (c) 2014 Nicira, Inc.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at:
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __NET_IF_H
+#define __NET_IF_H 1
+
+#include <Netioapi.h>
+
+#define IFNAMSIZ IF_NAMESIZE
+
+#endif /* net/if.h */
index eaeb386..833fee8 100644 (file)
@@ -41,7 +41,11 @@ void netdev_vport_inc_tx(const struct netdev *,
 
 const char *netdev_vport_class_get_dpif_port(const struct netdev_class *);
 
+#ifndef _WIN32
 enum { NETDEV_VPORT_NAME_BUFSIZE = 16 };
+#else
+enum { NETDEV_VPORT_NAME_BUFSIZE = 256 };
+#endif
 const char *netdev_vport_get_dpif_port(const struct netdev *,
                                        char namebuf[], size_t bufsize);
 char *netdev_vport_get_dpif_port_strdup(const struct netdev *);